testcafe 2.3.1 → 2.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (235) hide show
  1. package/CHANGELOG.md +150 -0
  2. package/LICENSE +1 -1
  3. package/README.md +40 -46
  4. package/bin/testcafe-with-v8-flag-filter.js +10 -16
  5. package/lib/api/exportable-lib/index.js +1 -11
  6. package/lib/api/structure/test.js +4 -11
  7. package/lib/api/test-controller/execution-context.js +4 -2
  8. package/lib/api/test-controller/index.js +8 -10
  9. package/lib/api/test-run-tracker.js +1 -1
  10. package/lib/assertions/executor.js +2 -11
  11. package/lib/browser/connection/gateway/index.js +272 -0
  12. package/lib/browser/connection/gateway/status.js +10 -0
  13. package/lib/browser/connection/index.js +60 -47
  14. package/lib/browser/connection/service-routes.js +4 -2
  15. package/lib/browser/provider/built-in/dedicated/chrome/cdp-client/index.js +3 -2
  16. package/lib/browser/provider/built-in/dedicated/chrome/index.js +48 -23
  17. package/lib/browser/provider/built-in/dedicated/edge/index.js +4 -1
  18. package/lib/browser/provider/index.js +13 -4
  19. package/lib/browser/provider/plugin-host.js +7 -1
  20. package/lib/cli/argument-parser/index.js +10 -16
  21. package/lib/cli/cli.js +4 -13
  22. package/lib/cli/remotes-wizard.js +2 -1
  23. package/lib/cli/utils/should-move-option-to-end.js +17 -0
  24. package/lib/client/automation/deps/hammerhead.js +24 -0
  25. package/lib/client/automation/deps/testcafe-core.js +24 -0
  26. package/lib/client/automation/index.js +567 -187
  27. package/lib/client/automation/index.min.js +1 -1
  28. package/lib/client/automation/playback/press/get-key-info.js +44 -0
  29. package/lib/client/automation/playback/press/utils.js +142 -0
  30. package/lib/client/automation/utils/get-key-code.js +15 -0
  31. package/lib/client/automation/utils/get-key-identifier.js +14 -0
  32. package/lib/client/automation/utils/is-letter.js +7 -0
  33. package/lib/client/automation/utils/key-identifier-maps.js +93 -0
  34. package/lib/client/browser/idle-page/index.html.mustache +2 -2
  35. package/lib/client/browser/idle-page/index.js +24 -11
  36. package/lib/client/core/index.js +67 -13
  37. package/lib/client/core/index.min.js +1 -1
  38. package/lib/client/core/utils/array.js +77 -0
  39. package/lib/client/core/utils/dom.js +459 -0
  40. package/lib/client/core/utils/send-request-to-frame.js +22 -0
  41. package/lib/client/core/utils/style.js +102 -0
  42. package/lib/client/core/utils/values/boundary-values.js +41 -0
  43. package/lib/client/driver/index.js +270 -242
  44. package/lib/client/driver/index.min.js +1 -1
  45. package/lib/client/test-run/iframe.js.mustache +6 -6
  46. package/lib/client/test-run/index.js.mustache +37 -33
  47. package/lib/client/ui/index.js +3238 -54
  48. package/lib/client/ui/index.min.js +1 -1
  49. package/lib/client/ui/sprite.svg +15 -0
  50. package/lib/client/ui/styles.css +184 -41
  51. package/lib/compiler/babel/load-libs.js +6 -6
  52. package/lib/compiler/compilers.js +7 -7
  53. package/lib/compiler/index.js +6 -6
  54. package/lib/compiler/interfaces.js +1 -1
  55. package/lib/compiler/test-file/add-export-api.js +3 -3
  56. package/lib/compiler/test-file/api-based.js +8 -37
  57. package/lib/compiler/test-file/formats/es-next/compiler.js +5 -5
  58. package/lib/compiler/test-file/formats/typescript/compiler.js +9 -9
  59. package/lib/compiler/test-file/get-exportable-lib-path.js +3 -3
  60. package/lib/configuration/configuration-base.js +9 -6
  61. package/lib/configuration/default-values.js +3 -3
  62. package/lib/configuration/formats.js +9 -5
  63. package/lib/configuration/interfaces.js +1 -1
  64. package/lib/configuration/option-names.js +3 -4
  65. package/lib/configuration/run-option-names.js +2 -2
  66. package/lib/configuration/testcafe-configuration.js +41 -24
  67. package/lib/configuration/types.js +1 -1
  68. package/lib/configuration/utils.js +32 -0
  69. package/lib/custom-client-scripts/client-script.js +2 -2
  70. package/lib/custom-client-scripts/get-code.js +3 -3
  71. package/lib/custom-client-scripts/routing.js +10 -12
  72. package/lib/errors/runtime/templates.js +3 -2
  73. package/lib/errors/test-run/templates.js +4 -1
  74. package/lib/errors/types.js +3 -1
  75. package/lib/index.js +6 -31
  76. package/lib/live/bootstrapper.js +3 -3
  77. package/lib/live/test-runner.js +9 -7
  78. package/lib/native-automation/add-custom-debug-formatters.js +23 -0
  79. package/lib/native-automation/api-base.js +27 -0
  80. package/lib/native-automation/client/event-descriptor.js +118 -0
  81. package/lib/native-automation/client/input.js +46 -0
  82. package/lib/native-automation/client/key-press/utils.js +31 -0
  83. package/lib/native-automation/client/types.js +11 -0
  84. package/lib/native-automation/client/utils.js +54 -0
  85. package/lib/native-automation/cookie-provider.js +115 -0
  86. package/lib/native-automation/empty-page-markup.js +11 -0
  87. package/lib/native-automation/error-route.js +7 -0
  88. package/lib/native-automation/errors.js +20 -0
  89. package/lib/native-automation/index.js +53 -0
  90. package/lib/native-automation/request-hooks/event-factory/frame-navigated-event-based.js +40 -0
  91. package/lib/native-automation/request-hooks/event-factory/request-paused-event-based.js +94 -0
  92. package/lib/native-automation/request-hooks/event-provider.js +55 -0
  93. package/lib/native-automation/request-hooks/pipeline-context.js +11 -0
  94. package/lib/{proxyless → native-automation}/request-pipeline/constants.js +1 -1
  95. package/lib/native-automation/request-pipeline/context-info.js +58 -0
  96. package/lib/native-automation/request-pipeline/index.js +329 -0
  97. package/lib/native-automation/request-pipeline/resendAuthRequest.js +23 -0
  98. package/lib/native-automation/request-pipeline/safe-api.js +66 -0
  99. package/lib/native-automation/request-pipeline/special-handlers.js +76 -0
  100. package/lib/native-automation/request-pipeline/test-run-bridge.js +45 -0
  101. package/lib/native-automation/resource-injector.js +175 -0
  102. package/lib/native-automation/session-storage/index.js +43 -0
  103. package/lib/native-automation/storages-provider.js +17 -0
  104. package/lib/native-automation/types.js +12 -0
  105. package/lib/native-automation/utils/cdp.js +71 -0
  106. package/lib/native-automation/utils/convert.js +11 -0
  107. package/lib/native-automation/utils/get-active-client.js +8 -0
  108. package/lib/native-automation/utils/headers.js +30 -0
  109. package/lib/native-automation/utils/string.js +32 -0
  110. package/lib/reporter/index.js +52 -4
  111. package/lib/reporter/interfaces.js +1 -1
  112. package/lib/reporter/plugin-host.js +44 -4
  113. package/lib/reporter/plugin-methods.js +2 -1
  114. package/lib/reporter/report-data-log.js +25 -0
  115. package/lib/role/role.js +4 -39
  116. package/lib/runner/bootstrapper.js +40 -15
  117. package/lib/runner/browser-job.js +4 -5
  118. package/lib/runner/fixture-hook-controller.js +1 -7
  119. package/lib/runner/index.js +87 -94
  120. package/lib/runner/interfaces.js +1 -1
  121. package/lib/runner/task/index.js +2 -32
  122. package/lib/runner/test-run-controller.js +46 -4
  123. package/lib/shared/errors/index.js +8 -2
  124. package/lib/shared/utils/is-file-protocol.js +2 -2
  125. package/lib/test-run/bookmark.js +5 -23
  126. package/lib/test-run/commands/actions.js +16 -4
  127. package/lib/test-run/commands/service.js +2 -3
  128. package/lib/test-run/commands/type.js +2 -1
  129. package/lib/test-run/commands/utils.js +4 -2
  130. package/lib/test-run/cookies/base.js +4 -1
  131. package/lib/test-run/cookies/factory.js +4 -4
  132. package/lib/test-run/cookies/provider.js +9 -2
  133. package/lib/test-run/execute-js-expression/index.js +4 -2
  134. package/lib/test-run/index.js +35 -151
  135. package/lib/test-run/request/create-request-options.js +37 -24
  136. package/lib/test-run/request/send.js +2 -3
  137. package/lib/test-run/role-provider.js +5 -5
  138. package/lib/test-run/session-controller.js +5 -5
  139. package/lib/test-run/storages/factory.js +4 -4
  140. package/lib/testcafe.js +17 -18
  141. package/lib/utils/check-is-vm.js +58 -0
  142. package/lib/utils/debug-loggers.js +9 -7
  143. package/lib/utils/get-browser.js +5 -2
  144. package/lib/utils/get-options/boolean-or-object-option.js +18 -0
  145. package/lib/utils/get-options/quarantine.js +10 -13
  146. package/lib/utils/get-options/skip-js-errors.js +12 -16
  147. package/lib/utils/parse-user-agent.js +20 -13
  148. package/lib/utils/string.js +1 -1
  149. package/package.json +14 -11
  150. package/ts-defs/index.d.ts +12 -2
  151. package/ts-defs/selectors.d.ts +8 -1
  152. package/ts-defs/testcafe-scripts.d.ts +8 -1
  153. package/lib/browser/connection/gateway.js +0 -205
  154. package/lib/compiler/test-file/test-file-temp-variable-name.js +0 -6
  155. package/lib/dashboard/config-storage.js +0 -26
  156. package/lib/dashboard/connector.js +0 -84
  157. package/lib/dashboard/documentation-url.js +0 -6
  158. package/lib/dashboard/formatting.js +0 -26
  159. package/lib/dashboard/get-dashboard-url.js +0 -10
  160. package/lib/dashboard/get-default-project-link.js +0 -23
  161. package/lib/dashboard/get-env-options.js +0 -26
  162. package/lib/dashboard/index.js +0 -145
  163. package/lib/dashboard/interfaces.js +0 -3
  164. package/lib/dashboard/messages.js +0 -21
  165. package/lib/proxyless/add-custom-debug-formatters.js +0 -22
  166. package/lib/proxyless/api-base.js +0 -25
  167. package/lib/proxyless/client/event-simulator.js +0 -40
  168. package/lib/proxyless/client/types.js +0 -11
  169. package/lib/proxyless/client/utils.js +0 -24
  170. package/lib/proxyless/cookie-provider.js +0 -87
  171. package/lib/proxyless/default-setup-options.js +0 -9
  172. package/lib/proxyless/empty-page-markup.js +0 -11
  173. package/lib/proxyless/error-route.js +0 -7
  174. package/lib/proxyless/index.js +0 -53
  175. package/lib/proxyless/request-hooks/event-factory/frame-navigated-event-based.js +0 -40
  176. package/lib/proxyless/request-hooks/event-factory/request-paused-event-based.js +0 -95
  177. package/lib/proxyless/request-hooks/event-provider.js +0 -52
  178. package/lib/proxyless/request-hooks/pipeline-context.js +0 -11
  179. package/lib/proxyless/request-pipeline/context-info.js +0 -55
  180. package/lib/proxyless/request-pipeline/index.js +0 -230
  181. package/lib/proxyless/request-pipeline/resendAuthRequest.js +0 -23
  182. package/lib/proxyless/request-pipeline/safe-api.js +0 -62
  183. package/lib/proxyless/request-pipeline/special-handlers.js +0 -73
  184. package/lib/proxyless/request-pipeline/test-run-bridge.js +0 -45
  185. package/lib/proxyless/resource-injector.js +0 -162
  186. package/lib/proxyless/session-storage/index.js +0 -39
  187. package/lib/proxyless/storages-provider.js +0 -17
  188. package/lib/proxyless/types.js +0 -10
  189. package/lib/proxyless/utils/cdp.js +0 -66
  190. package/lib/proxyless/utils/get-active-client.js +0 -8
  191. package/lib/proxyless/utils/headers.js +0 -30
  192. package/lib/proxyless/utils/string.js +0 -32
  193. package/lib/services/compiler/esm-runtime-holder-name.js +0 -6
  194. package/lib/services/compiler/host.js +0 -370
  195. package/lib/services/compiler/interfaces.js +0 -3
  196. package/lib/services/compiler/io.js +0 -10
  197. package/lib/services/compiler/protocol.js +0 -17
  198. package/lib/services/compiler/service-loader.js +0 -18
  199. package/lib/services/compiler/service.js +0 -361
  200. package/lib/services/compiler/test-run-proxy.js +0 -156
  201. package/lib/services/interfaces.js +0 -3
  202. package/lib/services/process-title.js +0 -10
  203. package/lib/services/serialization/prepare-options.js +0 -23
  204. package/lib/services/serialization/replicator/create-replicator.js +0 -58
  205. package/lib/services/serialization/replicator/interfaces.js +0 -3
  206. package/lib/services/serialization/replicator/transforms/base-transform.js +0 -16
  207. package/lib/services/serialization/replicator/transforms/browser-console-messages-transform.js +0 -23
  208. package/lib/services/serialization/replicator/transforms/callsite-record-transform.js +0 -24
  209. package/lib/services/serialization/replicator/transforms/command-base-trasform/assertion-command-constructors.js +0 -28
  210. package/lib/services/serialization/replicator/transforms/command-base-trasform/command-constructors.js +0 -66
  211. package/lib/services/serialization/replicator/transforms/command-base-trasform/index.js +0 -49
  212. package/lib/services/serialization/replicator/transforms/command-base-trasform/types.js +0 -3
  213. package/lib/services/serialization/replicator/transforms/configure-response-event-option-transform.js +0 -21
  214. package/lib/services/serialization/replicator/transforms/custom-error-transform.js +0 -29
  215. package/lib/services/serialization/replicator/transforms/function-marker-transform/index.js +0 -21
  216. package/lib/services/serialization/replicator/transforms/function-marker-transform/marker.js +0 -9
  217. package/lib/services/serialization/replicator/transforms/promise-marker-transform/index.js +0 -21
  218. package/lib/services/serialization/replicator/transforms/promise-marker-transform/marker.js +0 -9
  219. package/lib/services/serialization/replicator/transforms/raw-command-callsite-record-transform.js +0 -22
  220. package/lib/services/serialization/replicator/transforms/re-executable-promise-transform/index.js +0 -22
  221. package/lib/services/serialization/replicator/transforms/re-executable-promise-transform/marker.js +0 -6
  222. package/lib/services/serialization/replicator/transforms/request-filter-rule-transform.js +0 -23
  223. package/lib/services/serialization/replicator/transforms/request-hook-event-data-transform.js +0 -41
  224. package/lib/services/serialization/replicator/transforms/response-mock-transform.js +0 -23
  225. package/lib/services/serialization/replicator/transforms/role-transform.js +0 -21
  226. package/lib/services/serialization/replicator/transforms/testcafe-error-list-transform.js +0 -23
  227. package/lib/services/serialization/replicator/transforms/url-transform.js +0 -23
  228. package/lib/services/serialization/test-structure.js +0 -91
  229. package/lib/services/utils/ipc/interfaces.js +0 -29
  230. package/lib/services/utils/ipc/io.js +0 -109
  231. package/lib/services/utils/ipc/message.js +0 -84
  232. package/lib/services/utils/ipc/packet.js +0 -57
  233. package/lib/services/utils/ipc/proxy.js +0 -94
  234. package/lib/services/utils/ipc/transport.js +0 -65
  235. package/lib/services/utils/method-should-not-be-called-error.js +0 -10
@@ -1 +1 @@
1
- window["%hammerhead%"].utils.removeInjectedScript(),function Ue(Me){var Ae=Me.document;!function(s,o,t){var e="default"in s?s.default:s,i="default"in o?o.default:o;t=t&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t;var u={uiRoot:null,element:function(){return this.uiRoot||(this.uiRoot=Ae.createElement("div"),s.shadowUI.getRoot().appendChild(this.uiRoot)),this.uiRoot},hide:function(){this.uiRoot&&(this.uiRoot.style.visibility="hidden")},show:function(){this.uiRoot&&(this.uiRoot.style.visibility="")},remove:function(){var t=s.shadowUI.getRoot();s.nativeMethods.nodeParentNodeGetter.call(t).removeChild(t)}},h=e.shadowUI,c=e.utils.browser,a=e.utils.featureDetection,d=e.nativeMethods,p=e.eventSandbox.eventSimulator,m=e.eventSandbox.listeners,f=i.positionUtils,g=i.domUtils,v=i.styleUtils,y=i.eventUtils,C=i.arrayUtils,E=i.selectController,_="tcOptionList",r="disabled",w=c.isIE?30:20;function S(t){var e=d.eventTargetGetter.call(t),i=E.currentEl;(e||t.srcElement)===i||g.containsElement(i,e)||g.containsElement(E.optionList,e)||I()}function x(t,e,i){var n,s=d.eventTargetGetter.call(t),o=C.indexOf(E.options,s);o<0||(i(),(n=-1<s.className.indexOf(r))&&c.isWebKit||function(t,e){var i=E.currentEl,n=i.selectedIndex,s=i.getElementsByTagName("option")[t],o=!e&&t!==n;o&&!c.isIE&&(i.selectedIndex=t),c.isFirefox||c.isIE||!o||(p.input(i),p.change(i)),(c.isFirefox||c.isIE)&&p.mousedown(c.isFirefox?s:i),a.isTouchDevice||p.mouseup(c.isFirefox?s:i),(c.isFirefox||c.isIE)&&o&&(c.isIE&&(i.selectedIndex=t),c.isIE||p.input(i),p.change(i)),a.isTouchDevice||p.click(c.isFirefox||c.isIE?s:i),e||I()}(o,n))}function I(){g.remove(E.optionList),y.unbind(Ae,"mousedown",S),E.clear()}var n=Object.freeze({__proto__:null,expandOptionList:function(t){var e=t.children;if(e.length&&!t.disabled){if(E.currentEl){var i=t===E.currentEl;if(I(),i)return}var n=E.currentEl=t,s=E.optionList=Ae.createElement("div");u.element().appendChild(s),h.addClass(s,_),E.createChildren(e,s),m.addInternalEventBeforeListener(Me,["click"],x),d.setTimeout.call(Me,function(){y.bind(Ae,"mousedown",S)},0),v.set(s,{position:"absolute",fontSize:v.get(n,"fontSize"),fontFamily:v.get(n,"fontFamily"),minWidth:v.getWidth(n)+"px",left:f.getOffsetPosition(n).left+"px",height:g.getSelectVisibleChildren(t).length>w?v.getOptionHeight(t)*w:""});var o,a=f.getOffsetPosition(n).top,r=v.getHeight(s),l=a+v.getHeight(n)+2;l+r>v.getScrollTop(Me)+v.getHeight(Me)&&(o=a-3-r)>=v.getScrollTop(Me)&&(l=o),v.set(s,"top",l+"px")}},collapseOptionList:I,scrollOptionListByChild:function(t){var e,i,n,s,o,a,r=g.getSelectParent(t);r&&(e=v.getSelectElementSize(r),i=v.getOptionHeight(r),n=0,o=(s=Math.max(v.getScrollTop(r)/i,0))+e-1,(a=g.getChildVisibleIndex(r,t))<s?(n=i*(s-a),v.setScrollTop(r,Math.max(v.getScrollTop(r)-n,0))):o<a&&(n=i*(a-o),v.setScrollTop(r,v.getScrollTop(r)+n)))},getSelectChildCenter:function(t){var e=g.getSelectParent(t);if(!e)return{x:0,y:0};var i=v.getOptionHeight(e),n=f.getElementRectangle(t);return{x:Math.round(n.left+n.width/2),y:Math.round(n.top+i/2)}},switchOptionsByKeys:function(t,e){var i=v.getSelectElementSize(t),n=!v.hasDimensions(h.select("."+_)[0]);if(/down|up/.test(e)||!c.isIE&&(i<=1||c.isFirefox)&&(n||c.isFirefox)&&/left|right/.test(e)){for(var s=t.querySelectorAll("option"),o=[],a=0;a<s.length;a++){var r=s[a].parentElement;s[a].disabled||"optgroup"===g.getTagName(r)&&r.disabled||o.push(s[a])}var l=C.indexOf(o,s[t.selectedIndex])+(/down|right/.test(e)?1:-1);0<=l&&l<o.length&&(t.selectedIndex=C.indexOf(s,o[l]),c.isIE||p.input(t),p.change(t))}}}),l="Loading page...",b="modal-background",B="loading-text",T="loading-icon",U=null,M=null,A=null,V=!1;function D(){function t(){var t=o.styleUtils.getHeight(Me),e=o.styleUtils.getWidth(Me);o.styleUtils.set(U,"width",e+"px"),o.styleUtils.set(U,"height",t+"px"),o.styleUtils.set(A,{left:Math.round((e-o.styleUtils.getWidth(A))/2)+"px",top:Math.round((t-o.styleUtils.getHeight(A))/2)+"px"})}t(),o.eventUtils.bind(Me,"resize",t)}function R(){var t,e,i,n;t=u.element(),U=Ae.createElement("div"),t.appendChild(U),s.shadowUI.addClass(U,b),M=Ae.createElement("div"),s.nativeMethods.nodeTextContentSetter.call(M,l),t.appendChild(M),s.shadowUI.addClass(M,B),A=Ae.createElement("div"),o.styleUtils.set(A,"visibility","hidden"),t.appendChild(A),s.shadowUI.addClass(A,T),D(),e=o.styleUtils.getHeight(Me),i=o.styleUtils.getWidth(Me),(n=!o.styleUtils.hasDimensions(M))&&(o.styleUtils.set(M,"visibility","hidden"),o.styleUtils.set(M,"display","block")),o.styleUtils.set(M,{left:Math.max((i-o.styleUtils.getWidth(M))/2,0)+"px",top:Math.max((e-o.styleUtils.getHeight(M))/2,0)+"px"}),n&&(o.styleUtils.set(M,"display","none"),o.styleUtils.set(M,"visibility","")),V=!0}var P=Object.freeze({__proto__:null,initAndShowLoadingText:function(){function t(){R(),o.styleUtils.set(U,"opacity",.8),o.styleUtils.set(U,"display","block"),o.styleUtils.set(M,"display","block"),e=!0}var e=!1,i=function(){e||(Ae.body?t():s.nativeMethods.setTimeout.call(Me,i,0))};i(),o.eventUtils.documentReady().then(function(){e||t()})},show:function(t){V||R(),o.styleUtils.set(U,"opacity",t?0:.7),o.styleUtils.set(U,"display","block")},hide:function(){V&&(o.styleUtils.set(M,"display","none"),o.styleUtils.set(U,"display","none"))},showLoadingIcon:function(){o.styleUtils.set(A,"visibility","visible")},hideLoadingIcon:function(){o.styleUtils.set(A,"visibility","hidden")}}),k=e.shadowUI,W=i.styleUtils,O="success",F=(N.prototype.setValue=function(t){t="number"!=typeof t?0:Math.min(Math.max(t,0),100),W.set(this.valueElement,"width",t+"%")},N.prototype.setSuccess=function(t){t?k.addClass(this.containerElement,O):k.removeClass(this.containerElement,O)},N);function N(t){this.containerElement=Ae.createElement("div"),this.valueElement=Ae.createElement("div"),t.appendChild(this.containerElement),this.containerElement.appendChild(this.valueElement),k.addClass(this.containerElement,"progress-bar"),k.addClass(this.valueElement,"value")}var H=e.shadowUI,L=e.nativeMethods,q=i.eventUtils,z=i.styleUtils,G="progress-panel",j="title",K="content",Y=(X._getInvisibleElementProperty=function(t,e){var i="none"===z.get(t,"display");i&&z.set(t,"display","block");var n=t[e];return i&&z.set(t,"display","none"),n},X._showAtWindowCenter=function(t){var e=X._getInvisibleElementProperty(t,"offsetHeight"),i=X._getInvisibleElementProperty(t,"offsetWidth"),n=Math.round(z.getHeight(Me)/2-e/2),s=Math.round(z.getWidth(Me)/2-i/2);z.set(t,{left:s+"px",top:n+"px"})},X.prototype._setCurrentProgress=function(){var t=Math.round((L.dateNow()-this.startTime)/this.maxTimeout*100);this.progressBar.setValue(t)},X.prototype._setSuccess=function(t){this.progressBar.setSuccess(t)},X.prototype._stopAnimation=function(){L.clearInterval.call(Me,this.animationInterval)},X.prototype._animate=function(t,e,i,n){var s,o,a,r=this,l=L.dateNow(),u=i?0:1;i&&(z.set(t,"opacity",u),z.set(t,"display","block")),this._stopAnimation(),this.animationInterval=L.setInterval.call(Me,function(){s=L.dateNow()-l,o=Math.min(s/e,1),a=.5-Math.cos(o*Math.PI)/2,z.set(t,"opacity",u+(i?a:-a)),1===o&&(r._stopAnimation(),n&&n())},10)},X.prototype._showPanel=function(){q.bind(Me,"resize",this.disposePanel),this._animate(this.panelDiv,200,!0)},X.prototype._hidePanel=function(t){var e=this;this.startTime=null,q.unbind(Me,"resize",this.disposePanel),this._animate(this.panelDiv,t?0:600,!1,function(){return z.set(e.panelDiv,"display","none")})},X.prototype.show=function(t,e){var i=this;this.startTime=L.dateNow(),this.maxTimeout=e,L.nodeTextContentSetter.call(this.titleDiv,t),this._setSuccess(!1),this.openingTimeout=L.setTimeout.call(Me,function(){i.openingTimeout=null,i._setCurrentProgress(),i._showPanel(),i.updateInterval=L.setInterval.call(Me,function(){return i._setCurrentProgress()},100)},300)},X.prototype.close=function(t){var e=this;t&&this._setSuccess(!0),this.openingTimeout&&(L.clearTimeout.call(Me,this.openingTimeout),this.openingTimeout=null),this.updateInterval&&(L.clearInterval.call(Me,this.updateInterval),this.updateInterval=null),t?this.startTime&&L.dateNow()-this.startTime<1e3?L.setTimeout.call(Me,function(){L.setTimeout.call(Me,function(){return e._hidePanel(!1)},200)},100):L.setTimeout.call(Me,function(){return e._hidePanel(!1)},200):this._hidePanel(!0)},X);function X(){var t=this;this.startTime=null,this.openingTimeout=null,this.updateInterval=null,this.animationInterval=null,this.panelDiv=Ae.createElement("div"),u.element().appendChild(this.panelDiv),this.titleDiv=Ae.createElement("div"),this.panelDiv.appendChild(this.titleDiv),this.contentDiv=Ae.createElement("div"),this.panelDiv.appendChild(this.contentDiv),H.addClass(this.panelDiv,G),H.addClass(this.titleDiv,j),H.addClass(this.contentDiv,K),X._showAtWindowCenter(this.panelDiv),this.progressBar=new F(this.contentDiv),this.disposePanel=function(){return X._showAtWindowCenter(t.panelDiv)}}var J=function(t,e){return(J=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])})(t,e)};function Q(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}J(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}var Z=e.shadowUI,$=e.nativeMethods,tt=i.styleUtils,et="determinate",it=(nt.prototype._setCurrentProgress=function(){var t=($.dateNow()-this.startTime)/this.maxTimeout,e=Math.min(Math.max(t,0),1),i=tt.getWidth(this.progressBar),n=Math.round(i*e);tt.set(this.firstValueElement,"width",n+"px")},nt.prototype.start=function(t,e){var i=this;Z.addClass(this.progressBar,et),this.maxTimeout=t,this.startTime=e||$.dateNow(),this._setCurrentProgress(),this.animationInterval=$.setInterval.call(Me,function(){return i._setCurrentProgress()},10)},nt.prototype.stop=function(){this.animationInterval&&($.clearInterval.call(Me,this.animationInterval),this.animationInterval=null)},nt.prototype.reset=function(){tt.set(this.firstValueElement,"width",0),Z.removeClass(this.progressBar,et)},nt);function nt(t,e){this.progressBar=t,this.firstValueElement=e,this.maxTimeout=null,this.startTime=null,this.animationInterval=null}function st(t,e,i){if(e.x===t.x)return 0;var n=(e.y-t.y)/(e.x-t.x),s=t.x*(t.y-e.y)/(e.x-t.x)+t.y;return Math.round(n*i+s)}var ot=e.shadowUI,at=e.nativeMethods,rt=i.styleUtils,lt={time:2800,points:[.815,.395],positionByCompletePercent:{0:{left:-35,right:100},.6:{left:100,right:-90},1:{left:100,right:-90}}},ut={time:3e3,points:[.84,1],positionByCompletePercent:{0:{left:-200,right:100},.6:{left:107,right:-8},1:{left:107,right:-8}}},ht=0,ct=.6,dt=1,pt="indeterminate",mt=(ft._updateValueAnimation=function(t,e,i){var n,s,o,a,r,l,u,h,c,d,p=i.time,m=i.points,f=i.positionByCompletePercent,g=at.dateNow()-t,v=(n=g/p,s=m[0],o=m[1],3*Math.pow(1-n,2)*n*s+3*(1-n)*n*n*o+n*n*n),y=(h=(l=(a=v)<ct)?ct:dt,c=(r=f)[u=l?ht:ct],d=r[h],{left:st({x:u,y:c.left},{x:h,y:d.left},a),right:st({x:u,y:c.right},{x:h,y:d.right},a)}),C=y.left,E=y.right;rt.set(e,"left",Math.round(C)+"%"),rt.set(e,"right",Math.round(E)+"%")},ft.prototype._clearFirstValueAnimation=function(){this.animationInterval&&(at.clearInterval.call(Me,this.animationInterval),this.animationInterval=null),rt.set(this.firstValue,"left","-35%"),rt.set(this.firstValue,"right","100%")},ft.prototype._clearSecondValueAnimation=function(){this.secondValueAnimationInterval&&(at.clearInterval.call(Me,this.secondValueAnimationInterval),this.secondValueAnimationInterval=null),rt.set(this.secondValue,"left","-200%"),rt.set(this.secondValue,"right","100%")},ft.prototype._startFirstValueAnimation=function(){var t=this;this._clearFirstValueAnimation();var e=at.dateNow();this.animationInterval=at.setInterval.call(Me,function(){ft._updateValueAnimation(e,t.firstValue,lt)},10)},ft.prototype._startSecondValueAnimation=function(){var t=this;this._clearSecondValueAnimation();var e=at.dateNow();this.secondValueAnimationInterval=at.setInterval.call(Me,function(){ft._updateValueAnimation(e,t.secondValue,ut)},10)},ft.prototype._startAnimation=function(){var t=this;this._startFirstValueAnimation(),this.secondValueAnimationTimeout=at.setTimeout.call(Me,function(){return t._startSecondValueAnimation()},1e3),this.restartAnimationTimeout=at.setTimeout.call(Me,function(){return t._startAnimation()},1950)},ft.prototype._stopAnimation=function(){this._clearFirstValueAnimation(),this._clearSecondValueAnimation(),this.secondValueAnimationTimeout&&(at.clearInterval.call(Me,this.secondValueAnimationTimeout),this.secondValueAnimationTimeout=null),this.restartAnimationTimeout&&(at.clearInterval.call(Me,this.restartAnimationTimeout),this.restartAnimationTimeout=null)},ft.prototype.start=function(){ot.addClass(this.progressBar,pt),this._startAnimation()},ft.prototype.stop=function(){ot.removeClass(this.progressBar,pt),this._stopAnimation()},ft);function ft(t,e,i){this.progressBar=t,this.firstValue=e,this.secondValue=i,this.animationInterval=null,this.secondValueAnimationInterval=null,this.secondValueAnimationTimeout=null,this.restartAnimationTimeout=null}var gt=e.shadowUI,vt=i.styleUtils,yt=(Ct.prototype._create=function(t){this.progressBar=Ae.createElement("div"),gt.addClass(this.progressBar,"progress-bar"),t.appendChild(this.progressBar);var e=Ae.createElement("div");gt.addClass(e,"value-container"),this.progressBar.appendChild(e),this.firstValueElement=Ae.createElement("div"),gt.addClass(this.firstValueElement,"value"),e.appendChild(this.firstValueElement),this.secondValueElement=Ae.createElement("div"),gt.addClass(this.secondValueElement,"value"),e.appendChild(this.secondValueElement)},Ct.prototype.show=function(){vt.set(this.progressBar,"visibility","visible")},Ct.prototype.hide=function(){vt.set(this.progressBar,"visibility","hidden")},Ct);function Ct(t){this.progressBar=null,this.firstValueElement=null,this.secondValueElement=null,this._create(t),this.determinateIndicator=new it(this.progressBar,this.firstValueElement),this.indeterminateIndicator=new mt(this.progressBar,this.firstValueElement,this.secondValueElement)}var Et,_t="start-waiting-element",wt="end-waiting-element-request",St="end-waiting-element-response",xt="start-waiting-assertion-retries",It="end-waiting-assertion-retries-request",bt="end-waiting-assertion-retries-response",Bt="step",Tt="resume",Ut=e.Promise,Mt=e.shadowUI,At=e.nativeMethods,Vt=e.eventSandbox.message,Dt=e.utils.browser,Rt=e.utils.featureDetection,Pt=e.eventSandbox.listeners,kt=i.styleUtils,Wt=i.eventUtils,Ot=i.domUtils,Ft=i.serviceUtils,Nt=i.arrayUtils,Ht="waiting-element-failed",Lt="waiting-element-success",qt="%testCafeStatusPrefix%",zt=(Q(Gt,Et=Ft.EventEmitter),Object.defineProperty(Gt.prototype,"visibleHeight",{get:function(){return this.maxHeight=Math.max(this.maxHeight,kt.getHeight(this.statusBar)),this.maxHeight},enumerable:!1,configurable:!0}),Gt.prototype._createButton=function(t,e){var i=Ae.createElement("div"),n=Ae.createElement("div"),s=Ae.createElement("span");return At.nodeTextContentSetter.call(s,t),Mt.addClass(i,"button"),Mt.addClass(i,e),Mt.addClass(n,"button-icon"),Dt.isSafari&&(s.style.position="relative",s.style.top="1px"),i.appendChild(n),i.appendChild(s),i},Gt.prototype._createIconArea=function(){this.icon=Ae.createElement("div"),Mt.addClass(this.icon,"icon"),this.statusBar.appendChild(this.icon)},Gt.prototype._createInformationArea=function(){this.infoContainer=Ae.createElement("div"),Mt.addClass(this.infoContainer,"info-container"),this.statusBar.appendChild(this.infoContainer);var t=Ae.createElement("div");Mt.addClass(t,"info-text-container"),this.infoContainer.appendChild(t);var e=Ae.createElement("div");Mt.addClass(e,"status-container"),t.appendChild(e),this.statusDiv=Ae.createElement("div"),this.statusDiv=Ae.createElement("div"),At.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText("Loading Web Page...")),Mt.addClass(this.statusDiv,"status"),Mt.addClass(this.statusDiv,"info"),e.appendChild(this.statusDiv);var i=Ae.createElement("div");At.nodeTextContentSetter.call(i,"".concat(this.fixtureName," - ").concat(this.testName)),Mt.addClass(i,"fixture"),Mt.addClass(i,"info"),e.appendChild(i);var n=Ae.createElement("div");At.nodeTextContentSetter.call(n,this.userAgent),Mt.addClass(n,"user-agent"),t.appendChild(n)},Gt.prototype._createActionsArea=function(){var t=this;this.actionsContainer=Ae.createElement("div"),Mt.addClass(this.actionsContainer,"actions-container"),this.statusBar.appendChild(this.actionsContainer),this.buttons=Ae.createElement("div"),Mt.addClass(this.buttons,"buttons"),this.actionsContainer.appendChild(this.buttons),this.unlockButton=this._createButton("Unlock Page","locked"),this.resumeButton=this._createButton("Resume","resume"),this.nextButton=this._createButton("Next Action","step"),this.finishButton=this._createButton("Finish","finish"),this.buttons.appendChild(this.unlockButton),this.buttons.appendChild(this.resumeButton),this.buttons.appendChild(this.nextButton),this.actionsContainer.style.display="none",this._bindClickOnce([this.unlockButton],function(){Mt.removeClass(t.unlockButton,"locked"),Mt.addClass(t.unlockButton,"unlocked"),At.nodeTextContentSetter.call(t.unlockButton.querySelector("span"),"Page unlocked"),t.state.locked=!1,t.emit(t.UNLOCK_PAGE_BTN_CLICK,{})}),this.unlockButton.style.display="none"},Gt.prototype._create=function(){this.statusBar=Ae.createElement("div"),Mt.addClass(this.statusBar,"status-bar"),this._createIconArea(),this._createInformationArea(),this._createActionsArea(),this.progressBar=new yt(this.infoContainer),this.progressBar.indeterminateIndicator.start(),this.progressBar.show(),u.element().appendChild(this.statusBar),this._bindHandlers(),this.state.created=!0},Gt.prototype._createBeforeReady=function(){var t,e=this;this.state.created||(t=Me).top!==t||(Ae.body?this._create():At.setTimeout.call(Me,function(){return e._createBeforeReady()},0))},Gt.prototype._animate=function(t){var e,i,n,s=this,o=At.dateNow(),a=parseInt(kt.get(this.statusBar,"opacity"),10)||0;this._stopAnimation(),t&&(kt.set(this.statusBar,"visibility",""),this.state.hidden=!1),this.animationInterval=At.setInterval.call(Me,function(){e=At.dateNow()-o,i=Math.min(e/500,1),n=.5-Math.cos(i*Math.PI)/2,kt.set(s.statusBar,"opacity",a+(t?n:-n)),1===i&&(s._stopAnimation(),t||(kt.set(s.statusBar,"visibility","hidden"),s.state.hidden=!0),s.state.showing=!1,s.state.hiding=!1)},10)},Gt.prototype._stopAnimation=function(){this.animationInterval&&(At.clearInterval.call(Me,this.animationInterval),this.animationInterval=null)},Gt.prototype._fadeOut=function(){this.state.hiding||this.state.debugging||(this.state.showing=!1,this.state.hiding=!0,this._animate())},Gt.prototype._fadeIn=function(){this.state.showing||this.state.debugging||(this.state.hiding=!1,this.state.showing=!0,this._animate(!0))},Gt.prototype._bindHandlers=function(){var e=this;Pt.initElementListening(Me,["resize"]),Pt.addInternalEventBeforeListener(Me,["resize"],function(){e.windowHeight=Me.innerHeight}),Pt.addFirstInternalEventBeforeListener(Me,["mousemove","mouseout","touchmove"],function(t){"mouseout"!==t.type||t.relatedTarget?"mousemove"!==t.type&&"touchmove"!==t.type||(t.clientY>e.windowHeight-e.visibleHeight?e._fadeOut(t):e.state.hidden&&e._fadeIn(t)):e._fadeIn(t)})},Gt.prototype._bindClickOnce=function(i,n){var s=this,o=Rt.isTouchDevice?"touchstart":"mousedown",a=function(t){var e=At.eventTargetGetter.call(t);Nt.find(i,function(t){return Ot.containsElement(t,e)})?(Wt.preventDefault(t),Pt.removeInternalEventBeforeListener(Me,[o],a),n(t)):Ot.containsElement(s.statusBar,e)&&Wt.preventDefault(t)};Pt.addInternalEventBeforeListener(Me,[o],a)},Gt.prototype._initChildListening=function(){var i=this;Vt.on(Vt.SERVICE_MSG_RECEIVED_EVENT,function(t){var e=t.message;e.cmd===_t?i.showWaitingElementStatus(e.timeout):e.cmd===wt?i.hideWaitingElementStatus(e.waitingSuccess).then(function(){return Vt.sendServiceMsg({cmd:St},t.source)}):e.cmd===xt?i.showWaitingAssertionRetriesStatus(e.timeout):e.cmd===It&&i.hideWaitingAssertionRetriesStatus(e.waitingSuccess).then(function(){return Vt.sendServiceMsg({cmd:bt},t.source)})})},Gt.prototype._resetState=function(){this.state.debugging=!1,this.actionsContainer.style.display="none",this.unlockButton.style.display="none",At.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText("")),this.progressBar.hide()},Gt.prototype._getFullStatusText=function(t){var e=this.contextStorage.getItem(qt)||"";return e+(e&&t?". ":"")+t},Gt.prototype._showWaitingStatus=function(){var t=this.state.assertionRetries?"Waiting for assertion execution...":"Waiting for element to appear...";At.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText(t)),this.progressBar.show()},Gt.prototype._hideWaitingStatus=function(e){var i=this;return new Ut(function(t){At.setTimeout.call(Me,function(){i.state.waiting||i.state.debugging||(Mt.removeClass(i.statusBar,Lt),Mt.removeClass(i.statusBar,Ht),i.progressBar.determinateIndicator.reset(),i._resetState()),t()},e?0:500)})},Gt.prototype._showDebuggingStatus=function(t){var s=this;return new Ut(function(n){s.state.debugging=!0,s.state.locked=!0,t?(s.buttons.removeChild(s.nextButton),s.buttons.removeChild(s.resumeButton),s.buttons.appendChild(s.finishButton),At.nodeTextContentSetter.call(s.statusDiv,s._getFullStatusText("Test failed")),Mt.removeClass(s.statusBar,Lt),Mt.addClass(s.statusBar,Ht)):At.nodeTextContentSetter.call(s.statusDiv,s._getFullStatusText("Debugging test...")),s.actionsContainer.style.display="",s.unlockButton.style.display="",s._bindClickOnce([s.resumeButton,s.nextButton,s.finishButton],function(t){var e=At.eventTargetGetter.call(t),i=Ot.containsElement(s.nextButton,e);s._resetState(),n(i?Bt:Tt)})})},Gt.prototype._setWaitingStatus=function(t,e){var i=this;this.state.waiting=!0,this.progressBar.determinateIndicator.start(t,e),this.showingTimeout=At.setTimeout.call(Me,function(){i.showingTimeout=null,i._showWaitingStatus()},300)},Gt.prototype._resetWaitingStatus=function(t){this.state.waiting=!1,this.progressBar.determinateIndicator.stop(),t?Mt.addClass(this.statusBar,Lt):Mt.addClass(this.statusBar,Ht);var e=this.showingTimeout&&t;return this.showingTimeout&&(At.clearTimeout.call(Me,this.showingTimeout),this.showingTimeout=null,t||this._showWaitingStatus()),this._hideWaitingStatus(e)},Gt.prototype.hidePageLoadingStatus=function(){this.state.created||this._create(),this.progressBar.indeterminateIndicator.stop(),this._resetState()},Gt.prototype.showDebuggingStatus=function(t){return this._stopAnimation(),kt.set(this.statusBar,"opacity",1),kt.set(this.statusBar,"visibility",""),this.state.hiden=!1,this._showDebuggingStatus(t)},Gt.prototype.showWaitingElementStatus=function(t){this.state.assertionRetries||this._setWaitingStatus(t)},Gt.prototype.hideWaitingElementStatus=function(t){return this.state.assertionRetries?Ut.resolve():this._resetWaitingStatus(t)},Gt.prototype.showWaitingAssertionRetriesStatus=function(t,e){this.state.assertionRetries=!0,this._setWaitingStatus(t,e)},Gt.prototype.hideWaitingAssertionRetriesStatus=function(t){var e=this;return this._resetWaitingStatus(t).then(function(){e.state.assertionRetries=!1})},Gt.prototype.setStatusPrefix=function(t){this.contextStorage.setItem(qt,t),At.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText(""))},Gt);function Gt(t,e,i,n){var s=Et.call(this)||this;return s.UNLOCK_PAGE_BTN_CLICK="testcafe|ui|status-bar|unlock-page-btn-click",s.userAgent=t,s.fixtureName=e,s.testName=i,s.contextStorage=n,s.statusBar=null,s.infoContainer=null,s.actionsContainer=null,s.icon=null,s.resumeButton=null,s.finishButton=null,s.nextButton=null,s.statusDiv=null,s.buttons=null,s.progressBar=null,s.animationInterval=null,s.showingTimeout=null,s.windowHeight=Ae.documentElement?kt.getHeight(Me):Me.innerHeight,s.maxHeight=0,s.state={created:!1,showing:!1,hiding:!1,debugging:!1,waiting:!1,assertionRetries:!1,hidden:!1},s.currentView=null,s._createBeforeReady(),s._initChildListening(),s}var jt,Kt=i.sendRequestToFrame,Yt=e.eventSandbox.message,Xt=(Q(Jt,jt=zt),Jt.prototype.showWaitingElementStatus=function(t){Yt.sendServiceMsg({cmd:_t,timeout:t},Me.top)},Jt.prototype.hideWaitingElementStatus=function(t){return Kt({cmd:wt,waitingSuccess:t},St,Me.top)},Jt.prototype.showWaitingAssertionRetriesStatus=function(t){Yt.sendServiceMsg({cmd:xt,timeout:t},Me.top)},Jt.prototype.hideWaitingAssertionRetriesStatus=function(t){return Kt({cmd:It,waitingSuccess:t},bt,Me.top)},Jt);function Jt(){return jt.call(this)||this}var Qt="ui|cursor|move|request",Zt="ui|cursor|leftbuttondown|request",$t="ui|cursor|rightbuttondown|request",te="ui|cursor|buttonup|request",ee="ui|cursor|move|response",ie="ui|cursor|leftbuttondown|response",ne="ui|cursor|rightbuttondown|response",se="ui|cursor|buttonup|response",oe=e.Promise,ae=e.shadowUI,re=e.utils.browser,le=e.utils.featureDetection,ue=e.eventSandbox.message,he=i.styleUtils,ce=i.positionUtils,de="l-mouse-down",pe="r-mouse-down",me=[de,pe].join(" ");ue.on(ue.SERVICE_MSG_RECEIVED_EVENT,function(t){var e=t.message;switch(e.cmd){case Qt:e.shouldRender||(fe.shouldRender=e.shouldRender),fe.move(ce.getIframePointRelativeToParentFrame({x:e.x,y:e.y},t.source)).then(function(){return ue.sendServiceMsg({cmd:ee},t.source)});break;case Zt:fe.leftButtonDown().then(function(){return ue.sendServiceMsg({cmd:ie},t.source)});break;case $t:fe.rightButtonDown().then(function(){return ue.sendServiceMsg({cmd:ne},t.source)});break;case te:fe.buttonUp().then(function(){return ue.sendServiceMsg({cmd:se},t.source)})}});var fe={cursorElement:null,x:50,y:50,pointerOffsetX:0,pointerOffsetY:0,shouldRender:!0,_createElement:function(){this.cursorElement=Ae.createElement("div"),ae.addClass(this.cursorElement,"cursor"),le.isTouchDevice&&!re.isIE&&(ae.addClass(this.cursorElement,"touch"),this.pointerOffsetX=Math.ceil(he.getWidth(this.cursorElement)/2),this.pointerOffsetY=Math.ceil(he.getHeight(this.cursorElement)/2)),u.element().appendChild(this.cursorElement)},_ensureCursorElement:function(){return!!this.shouldRender&&(this.cursorElement||this._createElement(),!0)},isVisible:function(){return this.cursorElement&&"hidden"!==he.get(this.cursorElement,"visibility")},hide:function(){this._ensureCursorElement()&&this.isVisible()&&he.set(this.cursorElement,"visibility","hidden")},show:function(){this._ensureCursorElement()&&he.set(this.cursorElement,"visibility","")},move:function(t){return this._ensureCursorElement()&&(this.x=t.x,this.y=t.y,he.set(this.cursorElement,{left:this.x-this.pointerOffsetX+"px",top:this.y-this.pointerOffsetY+"px"})),oe.resolve()},leftButtonDown:function(){return this._ensureCursorElement()&&(ae.removeClass(this.cursorElement,me),ae.addClass(this.cursorElement,de)),oe.resolve()},rightButtonDown:function(){return this._ensureCursorElement()&&(ae.removeClass(this.cursorElement,me),ae.addClass(this.cursorElement,pe)),oe.resolve()},buttonUp:function(){return this._ensureCursorElement()&&ae.removeClass(this.cursorElement,me),oe.resolve()}},ge=e.utils.browser.isIE?1:0,ve={move:function(t){var e={cmd:Qt,x:t.x+ge,y:t.y+ge,shouldRender:this.shouldRender};return o.sendRequestToFrame(e,ee,Me.parent)},leftButtonDown:function(){return o.sendRequestToFrame({cmd:Zt},ie,Me.parent)},rightButtonDown:function(){return o.sendRequestToFrame({cmd:$t},ne,Me.parent)},buttonUp:function(){return o.sendRequestToFrame({cmd:te},se,Me.parent)}},ye={screenshotMark:null,_createMark:function(){this.screenshotMark=Ae.createElement("img"),s.shadowUI.addClass(this.screenshotMark,"screenshot-mark"),this.screenshotMark.style.right=10/Me.devicePixelRatio+"px",this.screenshotMark.style.width=32/Me.devicePixelRatio+"px",this.screenshotMark.style.height=10/Me.devicePixelRatio+"px",this.hide(),s.shadowUI.getRoot().appendChild(this.screenshotMark)},hide:function(){this.screenshotMark&&(this.screenshotMark.style.visibility="hidden")},show:function(t){this.screenshotMark||this._createMark(),s.nativeMethods.imageSrcSetter.call(this.screenshotMark,t),this.screenshotMark.style.visibility=""}},Ce=e.Promise,Ee=e.eventSandbox.message,_e=i.sendRequestToFrame,we="ui|hide|request",Se="ui|hide|response",xe="ui|show|request",Ie="ui|show|response";Ee.on(Ee.SERVICE_MSG_RECEIVED_EVENT,function(t){t.message.cmd===we?(u.hide(),Ee.sendServiceMsg({cmd:Se},t.source)):t.message.cmd===xe&&(u.show(),Ee.sendServiceMsg({cmd:Ie},t.source))});var be={};be.uiRoot=u,be.cursorUI=fe,be.iframeCursorUI=ve,be.selectElement=n,be.modalBackground=P,be.ProgressPanel=Y,be.StatusBar=zt,be.IframeStatusBar=Xt,be.hide=function(t){return t?_e({cmd:we},Se,Me.top):(u.hide(),Ce.resolve())},be.show=function(t){return t?_e({cmd:xe},Ie,Me.top):(u.show(),Ce.resolve())},be.showScreenshotMark=function(t){return ye.show(t)},be.hideScreenshotMark=function(){return ye.hide()};var Be=e.nativeMethods,Te=e.EVENTS.evalIframeScript;Be.objectDefineProperty(Me,"%testCafeUI%",{configurable:!0,value:be}),e.on(Te,function(t){return Ue(Be.contentWindowGetter.call(t.iframe))})}(Me["%hammerhead%"],Me["%testCafeCore%"],Me["%hammerhead%"].Promise)}(window);
1
+ window["%hammerhead%"].utils.removeInjectedScript(),function Wl(jl){var ql=jl.document;!function(u,c,e){var t="default"in u?u.default:u,n="default"in c?c.default:c;e=e&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e;var h={uiRoot:null,container:null,element:function(){return this.uiRoot||(this.uiRoot=ql.createElement("div"),u.shadowUI.getRoot().appendChild(this.uiRoot)),this.uiRoot},panelsContainer:function(){return this.container||(this.container=ql.createElement("div"),u.shadowUI.addClass(this.container,"panels-container"),this.element().appendChild(this.container)),this.container},insertFirstChildToPanelsContainer:function(t){var e=this.panelsContainer(),n=u.nativeMethods.nodeFirstChildGetter.call(e);e.insertBefore(t,n)},hide:function(){this.uiRoot&&(this.uiRoot.style.visibility="hidden")},show:function(){this.uiRoot&&(this.uiRoot.style.visibility="")},remove:function(){var t=u.shadowUI.getRoot();u.nativeMethods.nodeParentNodeGetter.call(t).removeChild(t)}},d=t.shadowUI,p=t.utils.browser,o=t.utils.featureDetection,f=t.nativeMethods,m=t.eventSandbox.eventSimulator,v=t.eventSandbox.listeners,g=n.positionUtils,y=n.domUtils,_=n.styleUtils,C=n.eventUtils,b=n.arrayUtils,E=n.selectController,w="tcOptionList",a="disabled",S=p.isIE?30:20;function T(t){var e=f.eventTargetGetter.call(t),n=E.currentEl;(e||t.srcElement)===n||y.containsElement(n,e)||y.containsElement(E.optionList,e)||I()}function x(t,e,n){var i,r=f.eventTargetGetter.call(t),s=b.indexOf(E.options,r);s<0||(n(),(i=-1<r.className.indexOf(a))&&p.isWebKit||function(t,e){var n=E.currentEl,i=n.selectedIndex,r=n.getElementsByTagName("option")[t],s=!e&&t!==i;s&&!p.isIE&&(n.selectedIndex=t),p.isFirefox||p.isIE||!s||(m.input(n),m.change(n)),(p.isFirefox||p.isIE)&&m.mousedown(p.isFirefox?r:n),o.isTouchDevice||m.mouseup(p.isFirefox?r:n),(p.isFirefox||p.isIE)&&s&&(p.isIE&&(n.selectedIndex=t),p.isIE||m.input(n),m.change(n)),o.isTouchDevice||m.click(p.isFirefox||p.isIE?r:n),e||I()}(s,i))}function I(){y.remove(E.optionList),C.unbind(ql,"mousedown",T),E.clear()}var i=Object.freeze({__proto__:null,expandOptionList:function(t){var e=t.children;if(e.length&&!t.disabled){if(E.currentEl){var n=t===E.currentEl;if(I(),n)return}var i=E.currentEl=t,r=E.optionList=ql.createElement("div");h.element().appendChild(r),d.addClass(r,w),E.createChildren(e,r),v.addInternalEventBeforeListener(jl,["click"],x),f.setTimeout.call(jl,function(){C.bind(ql,"mousedown",T)},0),_.set(r,{position:"absolute",fontSize:_.get(i,"fontSize"),fontFamily:_.get(i,"fontFamily"),minWidth:_.getWidth(i)+"px",left:g.getOffsetPosition(i).left+"px",height:y.getSelectVisibleChildren(t).length>S?_.getOptionHeight(t)*S:""});var s,o=g.getOffsetPosition(i).top,a=_.getHeight(r),l=o+_.getHeight(i)+2;l+a>_.getScrollTop(jl)+_.getHeight(jl)&&(s=o-3-a)>=_.getScrollTop(jl)&&(l=s),_.set(r,"top",l+"px")}},collapseOptionList:I,scrollOptionListByChild:function(t){var e,n,i,r,s,o,a=y.getSelectParent(t);a&&(e=_.getSelectElementSize(a),n=_.getOptionHeight(a),i=0,s=(r=Math.max(_.getScrollTop(a)/n,0))+e-1,(o=y.getChildVisibleIndex(a,t))<r?(i=n*(r-o),_.setScrollTop(a,Math.max(_.getScrollTop(a)-i,0))):s<o&&(i=n*(o-s),_.setScrollTop(a,_.getScrollTop(a)+i)))},getSelectChildCenter:function(t){var e=y.getSelectParent(t);if(!e)return{x:0,y:0};var n=_.getOptionHeight(e),i=g.getElementRectangle(t);return{x:Math.round(i.left+i.width/2),y:Math.round(i.top+n/2)}},switchOptionsByKeys:function(t,e){var n=_.getSelectElementSize(t),i=!_.hasDimensions(d.select("."+w)[0]);if(/down|up/.test(e)||!p.isIE&&(n<=1||p.isFirefox)&&(i||p.isFirefox)&&/left|right/.test(e)){for(var r=t.querySelectorAll("option"),s=[],o=0;o<r.length;o++){var a=r[o].parentElement;r[o].disabled||"optgroup"===y.getTagName(a)&&a.disabled||s.push(r[o])}var l=b.indexOf(s,r[t.selectedIndex])+(/down|right/.test(e)?1:-1);0<=l&&l<s.length&&(t.selectedIndex=b.indexOf(r,s[l]),p.isIE||m.input(t),m.change(t))}}}),r="Loading page...",s="modal-background",l="loading-text",A="loading-icon",M=null,B=null,N=null,U=!1;function R(){function t(){var t=c.styleUtils.getHeight(jl),e=c.styleUtils.getWidth(jl);c.styleUtils.set(M,"width",e+"px"),c.styleUtils.set(M,"height",t+"px"),c.styleUtils.set(N,{left:Math.round((e-c.styleUtils.getWidth(N))/2)+"px",top:Math.round((t-c.styleUtils.getHeight(N))/2)+"px"})}t(),c.eventUtils.bind(jl,"resize",t)}function D(){var t,e,n,i;t=h.element(),M=ql.createElement("div"),t.appendChild(M),u.shadowUI.addClass(M,s),B=ql.createElement("div"),u.nativeMethods.nodeTextContentSetter.call(B,r),t.appendChild(B),u.shadowUI.addClass(B,l),N=ql.createElement("div"),c.styleUtils.set(N,"visibility","hidden"),t.appendChild(N),u.shadowUI.addClass(N,A),R(),e=c.styleUtils.getHeight(jl),n=c.styleUtils.getWidth(jl),(i=!c.styleUtils.hasDimensions(B))&&(c.styleUtils.set(B,"visibility","hidden"),c.styleUtils.set(B,"display","block")),c.styleUtils.set(B,{left:Math.max((n-c.styleUtils.getWidth(B))/2,0)+"px",top:Math.max((e-c.styleUtils.getHeight(B))/2,0)+"px"}),i&&(c.styleUtils.set(B,"display","none"),c.styleUtils.set(B,"visibility","")),U=!0}var k=Object.freeze({__proto__:null,initAndShowLoadingText:function(){function t(){D(),c.styleUtils.set(M,"opacity",.8),c.styleUtils.set(M,"display","block"),c.styleUtils.set(B,"display","block"),e=!0}var e=!1,n=function(){e||(ql.body?t():u.nativeMethods.setTimeout.call(jl,n,0))};n(),c.eventUtils.documentReady().then(function(){e||t()})},show:function(t){U||D(),c.styleUtils.set(M,"opacity",t?0:.7),c.styleUtils.set(M,"display","block")},hide:function(){U&&(c.styleUtils.set(B,"display","none"),c.styleUtils.set(M,"display","none"))},showLoadingIcon:function(){c.styleUtils.set(N,"visibility","visible")},hideLoadingIcon:function(){c.styleUtils.set(N,"visibility","hidden")}}),V=t.shadowUI,O=n.styleUtils,P="success",F=($.prototype.setValue=function(t){t="number"!=typeof t?0:Math.min(Math.max(t,0),100),O.set(this.valueElement,"width",t+"%")},$.prototype.setSuccess=function(t){t?V.addClass(this.containerElement,P):V.removeClass(this.containerElement,P)},$);function $(t){this.containerElement=ql.createElement("div"),this.valueElement=ql.createElement("div"),t.appendChild(this.containerElement),this.containerElement.appendChild(this.valueElement),V.addClass(this.containerElement,"progress-bar"),V.addClass(this.valueElement,"value")}var L=t.shadowUI,z=t.nativeMethods,H=n.eventUtils,W=n.styleUtils,j="progress-panel",q="title",G="content",Y=(X._getInvisibleElementProperty=function(t,e){var n="none"===W.get(t,"display");n&&W.set(t,"display","block");var i=t[e];return n&&W.set(t,"display","none"),i},X._showAtWindowCenter=function(t){var e=X._getInvisibleElementProperty(t,"offsetHeight"),n=X._getInvisibleElementProperty(t,"offsetWidth"),i=Math.round(W.getHeight(jl)/2-e/2),r=Math.round(W.getWidth(jl)/2-n/2);W.set(t,{left:r+"px",top:i+"px"})},X.prototype._setCurrentProgress=function(){var t=Math.round((z.dateNow()-this.startTime)/this.maxTimeout*100);this.progressBar.setValue(t)},X.prototype._setSuccess=function(t){this.progressBar.setSuccess(t)},X.prototype._stopAnimation=function(){z.clearInterval.call(jl,this.animationInterval)},X.prototype._animate=function(t,e,n,i){var r,s,o,a=this,l=z.dateNow(),u=n?0:1;n&&(W.set(t,"opacity",u),W.set(t,"display","block")),this._stopAnimation(),this.animationInterval=z.setInterval.call(jl,function(){r=z.dateNow()-l,s=Math.min(r/e,1),o=.5-Math.cos(s*Math.PI)/2,W.set(t,"opacity",u+(n?o:-o)),1===s&&(a._stopAnimation(),i&&i())},10)},X.prototype._showPanel=function(){H.bind(jl,"resize",this.disposePanel),this._animate(this.panelDiv,200,!0)},X.prototype._hidePanel=function(t){var e=this;this.startTime=null,H.unbind(jl,"resize",this.disposePanel),this._animate(this.panelDiv,t?0:600,!1,function(){return W.set(e.panelDiv,"display","none")})},X.prototype.show=function(t,e){var n=this;this.startTime=z.dateNow(),this.maxTimeout=e,z.nodeTextContentSetter.call(this.titleDiv,t),this._setSuccess(!1),this.openingTimeout=z.setTimeout.call(jl,function(){n.openingTimeout=null,n._setCurrentProgress(),n._showPanel(),n.updateInterval=z.setInterval.call(jl,function(){return n._setCurrentProgress()},100)},300)},X.prototype.close=function(t){var e=this;t&&this._setSuccess(!0),this.openingTimeout&&(z.clearTimeout.call(jl,this.openingTimeout),this.openingTimeout=null),this.updateInterval&&(z.clearInterval.call(jl,this.updateInterval),this.updateInterval=null),t?this.startTime&&z.dateNow()-this.startTime<1e3?z.setTimeout.call(jl,function(){z.setTimeout.call(jl,function(){return e._hidePanel(!1)},200)},100):z.setTimeout.call(jl,function(){return e._hidePanel(!1)},200):this._hidePanel(!0)},X);function X(){var t=this;this.startTime=null,this.openingTimeout=null,this.updateInterval=null,this.animationInterval=null,this.panelDiv=ql.createElement("div"),h.element().appendChild(this.panelDiv),this.titleDiv=ql.createElement("div"),this.panelDiv.appendChild(this.titleDiv),this.contentDiv=ql.createElement("div"),this.panelDiv.appendChild(this.contentDiv),L.addClass(this.panelDiv,j),L.addClass(this.titleDiv,q),L.addClass(this.contentDiv,G),X._showAtWindowCenter(this.panelDiv),this.progressBar=new F(this.contentDiv),this.disposePanel=function(){return X._showAtWindowCenter(t.panelDiv)}}var K=function(t,e){return(K=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function J(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}K(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function Q(t,o,a,l){return new(a=a||e)(function(n,e){function i(t){try{s(l.next(t))}catch(t){e(t)}}function r(t){try{s(l.throw(t))}catch(t){e(t)}}function s(t){var e;t.done?n(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(i,r)}s((l=l.apply(t,o||[])).next())})}function Z(n,i){var r,s,o,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(e){return function(t){return function(e){if(r)throw new TypeError("Generator is already executing.");for(;l&&e[l=0]&&(a=0),a;)try{if(r=1,s&&(o=2&e[0]?s.return:e[0]?s.throw||((o=s.return)&&o.call(s),0):s.next)&&!(o=o.call(s,e[1])).done)return o;switch(s=0,o&&(e=[2&e[0],o.value]),e[0]){case 0:case 1:o=e;break;case 4:return a.label++,{value:e[1],done:!1};case 5:a.label++,s=e[1],e=[0];continue;case 7:e=a.ops.pop(),a.trys.pop();continue;default:if(!(o=0<(o=a.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){a=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){a.label=e[1];break}if(6===e[0]&&a.label<o[1]){a.label=o[1],o=e;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(e);break}o[2]&&a.ops.pop(),a.trys.pop();continue}e=i.call(n,a)}catch(t){e=[6,t],s=0}finally{r=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}var tt=t.shadowUI,et=t.nativeMethods,nt=n.styleUtils,it="determinate",rt=(st.prototype._setCurrentProgress=function(){var t=(et.dateNow()-this.startTime)/this.maxTimeout,e=Math.min(Math.max(t,0),1),n=nt.getWidth(this.progressBar),i=Math.round(n*e);nt.set(this.firstValueElement,"width",i+"px")},st.prototype.start=function(t,e){var n=this;tt.addClass(this.progressBar,it),this.maxTimeout=t,this.startTime=e||et.dateNow(),this._setCurrentProgress(),this.animationInterval=et.setInterval.call(jl,function(){return n._setCurrentProgress()},10)},st.prototype.stop=function(){this.animationInterval&&(et.clearInterval.call(jl,this.animationInterval),this.animationInterval=null)},st.prototype.reset=function(){nt.set(this.firstValueElement,"width",0),tt.removeClass(this.progressBar,it)},st);function st(t,e){this.progressBar=t,this.firstValueElement=e,this.maxTimeout=null,this.startTime=null,this.animationInterval=null}function ot(t,e,n){if(e.x===t.x)return 0;var i=(e.y-t.y)/(e.x-t.x),r=t.x*(t.y-e.y)/(e.x-t.x)+t.y;return Math.round(i*n+r)}var at=t.shadowUI,lt=t.nativeMethods,ut=n.styleUtils,ct={time:2800,points:[.815,.395],positionByCompletePercent:{0:{left:-35,right:100},.6:{left:100,right:-90},1:{left:100,right:-90}}},ht={time:3e3,points:[.84,1],positionByCompletePercent:{0:{left:-200,right:100},.6:{left:107,right:-8},1:{left:107,right:-8}}},dt=0,pt=.6,ft=1,mt="indeterminate",vt=(gt._updateValueAnimation=function(t,e,n){var i,r,s,o,a,l,u,c,h,d,p=n.time,f=n.points,m=n.positionByCompletePercent,v=lt.dateNow()-t,g=(i=v/p,r=f[0],s=f[1],3*Math.pow(1-i,2)*i*r+3*(1-i)*i*i*s+i*i*i),y=(c=(l=(o=g)<pt)?pt:ft,h=(a=m)[u=l?dt:pt],d=a[c],{left:ot({x:u,y:h.left},{x:c,y:d.left},o),right:ot({x:u,y:h.right},{x:c,y:d.right},o)}),_=y.left,C=y.right;ut.set(e,"left",Math.round(_)+"%"),ut.set(e,"right",Math.round(C)+"%")},gt.prototype._clearFirstValueAnimation=function(){this.animationInterval&&(lt.clearInterval.call(jl,this.animationInterval),this.animationInterval=null),ut.set(this.firstValue,"left","-35%"),ut.set(this.firstValue,"right","100%")},gt.prototype._clearSecondValueAnimation=function(){this.secondValueAnimationInterval&&(lt.clearInterval.call(jl,this.secondValueAnimationInterval),this.secondValueAnimationInterval=null),ut.set(this.secondValue,"left","-200%"),ut.set(this.secondValue,"right","100%")},gt.prototype._startFirstValueAnimation=function(){var t=this;this._clearFirstValueAnimation();var e=lt.dateNow();this.animationInterval=lt.setInterval.call(jl,function(){gt._updateValueAnimation(e,t.firstValue,ct)},10)},gt.prototype._startSecondValueAnimation=function(){var t=this;this._clearSecondValueAnimation();var e=lt.dateNow();this.secondValueAnimationInterval=lt.setInterval.call(jl,function(){gt._updateValueAnimation(e,t.secondValue,ht)},10)},gt.prototype._startAnimation=function(){var t=this;this._startFirstValueAnimation(),this.secondValueAnimationTimeout=lt.setTimeout.call(jl,function(){return t._startSecondValueAnimation()},1e3),this.restartAnimationTimeout=lt.setTimeout.call(jl,function(){return t._startAnimation()},1950)},gt.prototype._stopAnimation=function(){this._clearFirstValueAnimation(),this._clearSecondValueAnimation(),this.secondValueAnimationTimeout&&(lt.clearInterval.call(jl,this.secondValueAnimationTimeout),this.secondValueAnimationTimeout=null),this.restartAnimationTimeout&&(lt.clearInterval.call(jl,this.restartAnimationTimeout),this.restartAnimationTimeout=null)},gt.prototype.start=function(){at.addClass(this.progressBar,mt),this._startAnimation()},gt.prototype.stop=function(){at.removeClass(this.progressBar,mt),this._stopAnimation()},gt);function gt(t,e,n){this.progressBar=t,this.firstValue=e,this.secondValue=n,this.animationInterval=null,this.secondValueAnimationInterval=null,this.secondValueAnimationTimeout=null,this.restartAnimationTimeout=null}var yt=t.shadowUI,_t=n.styleUtils,Ct=(bt.prototype._create=function(t){this.progressBar=ql.createElement("div"),yt.addClass(this.progressBar,"progress-bar"),t.appendChild(this.progressBar);var e=ql.createElement("div");yt.addClass(e,"value-container"),this.progressBar.appendChild(e),this.firstValueElement=ql.createElement("div"),yt.addClass(this.firstValueElement,"value"),e.appendChild(this.firstValueElement),this.secondValueElement=ql.createElement("div"),yt.addClass(this.secondValueElement,"value"),e.appendChild(this.secondValueElement)},bt.prototype.show=function(){_t.set(this.progressBar,"visibility","visible")},bt.prototype.hide=function(){_t.set(this.progressBar,"visibility","hidden")},bt);function bt(t){this.progressBar=null,this.firstValueElement=null,this.secondValueElement=null,this._create(t),this.determinateIndicator=new rt(this.progressBar,this.firstValueElement),this.indeterminateIndicator=new vt(this.progressBar,this.firstValueElement,this.secondValueElement)}var Et,wt="start-waiting-element",St="end-waiting-element-request",Tt="end-waiting-element-response",xt="start-waiting-assertion-retries",It="end-waiting-assertion-retries-request",At="end-waiting-assertion-retries-response",Mt="step",Bt="resume",Nt=t.Promise,Ut=t.shadowUI,Rt=t.nativeMethods,Dt=t.eventSandbox.message,kt=t.utils.browser,Vt=t.utils.featureDetection,Ot=t.eventSandbox.listeners,Pt=n.styleUtils,Ft=n.eventUtils,$t=n.domUtils,Lt=n.serviceUtils,zt=n.arrayUtils,Ht="waiting-element-failed",Wt="waiting-element-success",jt="%testCafeStatusPrefix%",qt=(J(Gt,Et=Lt.EventEmitter),Object.defineProperty(Gt.prototype,"visibleHeight",{get:function(){return this.maxHeight=Math.max(this.maxHeight,Pt.getHeight(this.statusBar)),this.maxHeight},enumerable:!1,configurable:!0}),Gt.prototype._createButton=function(t,e){var n=ql.createElement("div"),i=ql.createElement("div"),r=ql.createElement("span");return Rt.nodeTextContentSetter.call(r,t),Ut.addClass(n,"button"),Ut.addClass(n,e),Ut.addClass(i,"button-icon"),kt.isSafari&&(r.style.position="relative",r.style.top="1px"),n.appendChild(i),n.appendChild(r),n},Gt.prototype._createIconArea=function(){this.icon=ql.createElement("div"),Ut.addClass(this.icon,"icon"),this.statusBar.appendChild(this.icon)},Gt.prototype._createInformationArea=function(){this.infoContainer=ql.createElement("div"),Ut.addClass(this.infoContainer,"info-container"),this.statusBar.appendChild(this.infoContainer);var t=ql.createElement("div");Ut.addClass(t,"info-text-container"),this.infoContainer.appendChild(t);var e=ql.createElement("div");Ut.addClass(e,"status-container"),t.appendChild(e),this.statusDiv=ql.createElement("div"),this.statusDiv=ql.createElement("div"),Rt.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText("Loading Web Page...")),Ut.addClass(this.statusDiv,"status"),Ut.addClass(this.statusDiv,"info"),e.appendChild(this.statusDiv);var n=ql.createElement("div");Rt.nodeTextContentSetter.call(n,"".concat(this.fixtureName," - ").concat(this.testName)),Ut.addClass(n,"fixture"),Ut.addClass(n,"info"),e.appendChild(n);var i=ql.createElement("div");Rt.nodeTextContentSetter.call(i,this.userAgent),Ut.addClass(i,"user-agent"),t.appendChild(i)},Gt.prototype._createActionsArea=function(){var t=this;this.actionsContainer=ql.createElement("div"),Ut.addClass(this.actionsContainer,"actions-container"),this.statusBar.appendChild(this.actionsContainer),this.buttons=ql.createElement("div"),Ut.addClass(this.buttons,"buttons"),this.actionsContainer.appendChild(this.buttons),this.unlockButton=this._createButton("Unlock Page","locked"),this.resumeButton=this._createButton("Resume","resume"),this.nextButton=this._createButton("Next Action","step"),this.finishButton=this._createButton("Finish","finish"),this.buttons.appendChild(this.unlockButton),this.buttons.appendChild(this.resumeButton),this.buttons.appendChild(this.nextButton),this.actionsContainer.style.display="none",this._bindClickOnce([this.unlockButton],function(){Ut.removeClass(t.unlockButton,"locked"),Ut.addClass(t.unlockButton,"unlocked"),Rt.nodeTextContentSetter.call(t.unlockButton.querySelector("span"),"Page unlocked"),t.state.locked=!1,t.emit(t.UNLOCK_PAGE_BTN_CLICK,{})}),this.unlockButton.style.display="none"},Gt.prototype._create=function(){this.statusBar=ql.createElement("div"),Ut.addClass(this.statusBar,"status-bar"),this._createIconArea(),this._createInformationArea(),this._createActionsArea(),this.progressBar=new Ct(this.infoContainer),this.progressBar.indeterminateIndicator.start(),this.progressBar.show(),h.panelsContainer().appendChild(this.statusBar),this._bindHandlers(),this.state.created=!0},Gt.prototype._createBeforeReady=function(){var t,e=this;this.state.created||(t=jl).top!==t||(ql.body?this._create():Rt.setTimeout.call(jl,function(){return e._createBeforeReady()},0))},Gt.prototype._animate=function(t){var e,n,i,r=this,s=Rt.dateNow(),o=parseInt(Pt.get(this.statusBar,"opacity"),10)||0;this._stopAnimation(),t&&(Pt.set(this.statusBar,"visibility",""),this.state.hidden=!1),this.animationInterval=Rt.setInterval.call(jl,function(){e=Rt.dateNow()-s,n=Math.min(e/500,1),i=.5-Math.cos(n*Math.PI)/2,Pt.set(r.statusBar,"opacity",o+(t?i:-i)),1===n&&(r._stopAnimation(),t||(Pt.set(r.statusBar,"visibility","hidden"),r.state.hidden=!0),r.state.showing=!1,r.state.hiding=!1)},10)},Gt.prototype._stopAnimation=function(){this.animationInterval&&(Rt.clearInterval.call(jl,this.animationInterval),this.animationInterval=null)},Gt.prototype._fadeOut=function(){this.state.hiding||this.state.debugging||(this.state.showing=!1,this.state.hiding=!0,this._animate())},Gt.prototype._fadeIn=function(){this.state.showing||this.state.debugging||(this.state.hiding=!1,this.state.showing=!0,this._animate(!0))},Gt.prototype._bindHandlers=function(){var e=this;Ot.initElementListening(jl,["resize"]),Ot.addInternalEventBeforeListener(jl,["resize"],function(){e.windowHeight=jl.innerHeight}),Ot.addFirstInternalEventBeforeListener(jl,["mousemove","mouseout","touchmove"],function(t){"mouseout"!==t.type||t.relatedTarget?"mousemove"!==t.type&&"touchmove"!==t.type||(t.clientY>e.windowHeight-e.visibleHeight?e._fadeOut(t):e.state.hidden&&e._fadeIn(t)):e._fadeIn(t)})},Gt.prototype._bindClickOnce=function(n,i){var r=this,s=Vt.isTouchDevice?"touchstart":"mousedown",o=function(t){var e=Rt.eventTargetGetter.call(t);zt.find(n,function(t){return $t.containsElement(t,e)})?(Ft.preventDefault(t),Ot.removeInternalEventBeforeListener(jl,[s],o),i(t)):$t.containsElement(r.statusBar,e)&&Ft.preventDefault(t)};Ot.addInternalEventBeforeListener(jl,[s],o)},Gt.prototype._initChildListening=function(){var n=this;Dt.on(Dt.SERVICE_MSG_RECEIVED_EVENT,function(t){var e=t.message;e.cmd===wt?n.showWaitingElementStatus(e.timeout):e.cmd===St?n.hideWaitingElementStatus(e.waitingSuccess).then(function(){return Dt.sendServiceMsg({cmd:Tt},t.source)}):e.cmd===xt?n.showWaitingAssertionRetriesStatus(e.timeout):e.cmd===It&&n.hideWaitingAssertionRetriesStatus(e.waitingSuccess).then(function(){return Dt.sendServiceMsg({cmd:At},t.source)})})},Gt.prototype._resetState=function(){this.state.debugging=!1,this.actionsContainer.style.display="none",this.unlockButton.style.display="none",Rt.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText("")),this.progressBar.hide()},Gt.prototype._getFullStatusText=function(t){var e=this.contextStorage.getItem(jt)||"";return e+(e&&t?". ":"")+t},Gt.prototype._showWaitingStatus=function(){var t=this.state.assertionRetries?"Waiting for assertion execution...":"Waiting for element to appear...";Rt.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText(t)),this.progressBar.show()},Gt.prototype._hideWaitingStatus=function(e){var n=this;return new Nt(function(t){Rt.setTimeout.call(jl,function(){n.state.waiting||n.state.debugging||(Ut.removeClass(n.statusBar,Wt),Ut.removeClass(n.statusBar,Ht),n.progressBar.determinateIndicator.reset(),n._resetState()),t()},e?0:500)})},Gt.prototype._showDebuggingStatus=function(t){var r=this;return new Nt(function(i){r.state.debugging=!0,r.state.locked=!0,t?(r.buttons.removeChild(r.nextButton),r.buttons.removeChild(r.resumeButton),r.buttons.appendChild(r.finishButton),Rt.nodeTextContentSetter.call(r.statusDiv,r._getFullStatusText("Test failed")),Ut.removeClass(r.statusBar,Wt),Ut.addClass(r.statusBar,Ht)):Rt.nodeTextContentSetter.call(r.statusDiv,r._getFullStatusText("Debugging test...")),r.actionsContainer.style.display="",r.unlockButton.style.display="",r._bindClickOnce([r.resumeButton,r.nextButton,r.finishButton],function(t){var e=Rt.eventTargetGetter.call(t),n=$t.containsElement(r.nextButton,e);r._resetState(),i(n?Mt:Bt)})})},Gt.prototype._setWaitingStatus=function(t,e){var n=this;this.state.waiting=!0,this.progressBar.determinateIndicator.start(t,e),this.showingTimeout=Rt.setTimeout.call(jl,function(){n.showingTimeout=null,n._showWaitingStatus()},300)},Gt.prototype._resetWaitingStatus=function(t){this.state.waiting=!1,this.progressBar.determinateIndicator.stop(),t?Ut.addClass(this.statusBar,Wt):Ut.addClass(this.statusBar,Ht);var e=this.showingTimeout&&t;return this.showingTimeout&&(Rt.clearTimeout.call(jl,this.showingTimeout),this.showingTimeout=null,t||this._showWaitingStatus()),this._hideWaitingStatus(e)},Gt.prototype.hidePageLoadingStatus=function(){this.state.created||this._create(),this.progressBar.indeterminateIndicator.stop(),this._resetState()},Gt.prototype.showDebuggingStatus=function(t){return this._stopAnimation(),Pt.set(this.statusBar,"opacity",1),Pt.set(this.statusBar,"visibility",""),this.state.hiden=!1,this._showDebuggingStatus(t)},Gt.prototype.showWaitingElementStatus=function(t){this.state.assertionRetries||this._setWaitingStatus(t)},Gt.prototype.hideWaitingElementStatus=function(t){return this.state.assertionRetries?Nt.resolve():this._resetWaitingStatus(t)},Gt.prototype.showWaitingAssertionRetriesStatus=function(t,e){this.state.assertionRetries=!0,this._setWaitingStatus(t,e)},Gt.prototype.hideWaitingAssertionRetriesStatus=function(t){var e=this;return this._resetWaitingStatus(t).then(function(){e.state.assertionRetries=!1})},Gt.prototype.setStatusPrefix=function(t){this.contextStorage.setItem(jt,t),Rt.nodeTextContentSetter.call(this.statusDiv,this._getFullStatusText(""))},Gt);function Gt(t,e,n,i){var r=Et.call(this)||this;return r.UNLOCK_PAGE_BTN_CLICK="testcafe|ui|status-bar|unlock-page-btn-click",r.userAgent=t,r.fixtureName=e,r.testName=n,r.contextStorage=i,r.statusBar=null,r.infoContainer=null,r.actionsContainer=null,r.icon=null,r.resumeButton=null,r.finishButton=null,r.nextButton=null,r.statusDiv=null,r.buttons=null,r.progressBar=null,r.animationInterval=null,r.showingTimeout=null,r.windowHeight=ql.documentElement?Pt.getHeight(jl):jl.innerHeight,r.maxHeight=0,r.state={created:!1,showing:!1,hiding:!1,debugging:!1,waiting:!1,assertionRetries:!1,hidden:!1},r.currentView=null,r._createBeforeReady(),r._initChildListening(),r}var Yt,Xt=n.sendRequestToFrame,Kt=t.eventSandbox.message,Jt=(J(Qt,Yt=qt),Qt.prototype.showWaitingElementStatus=function(t){Kt.sendServiceMsg({cmd:wt,timeout:t},jl.top)},Qt.prototype.hideWaitingElementStatus=function(t){return Xt({cmd:St,waitingSuccess:t},Tt,jl.top)},Qt.prototype.showWaitingAssertionRetriesStatus=function(t){Kt.sendServiceMsg({cmd:xt,timeout:t},jl.top)},Qt.prototype.hideWaitingAssertionRetriesStatus=function(t){return Xt({cmd:It,waitingSuccess:t},At,jl.top)},Qt);function Qt(){return Yt.call(this)||this}var Zt="ui|cursor|move|request",te="ui|cursor|leftbuttondown|request",ee="ui|cursor|rightbuttondown|request",ne="ui|cursor|buttonup|request",ie="ui|cursor|move|response",re="ui|cursor|leftbuttondown|response",se="ui|cursor|rightbuttondown|response",oe="ui|cursor|buttonup|response",ae=t.Promise,le=t.shadowUI,ue=t.utils.browser,ce=t.utils.featureDetection,he=t.eventSandbox.message,de=n.styleUtils,pe=n.positionUtils,fe="l-mouse-down",me="r-mouse-down",ve=[fe,me].join(" ");he.on(he.SERVICE_MSG_RECEIVED_EVENT,function(t){var e=t.message;switch(e.cmd){case Zt:ge.move(pe.getIframePointRelativeToParentFrame({x:e.x,y:e.y},t.source)).then(function(){return he.sendServiceMsg({cmd:ie},t.source)});break;case te:ge.leftButtonDown().then(function(){return he.sendServiceMsg({cmd:re},t.source)});break;case ee:ge.rightButtonDown().then(function(){return he.sendServiceMsg({cmd:se},t.source)});break;case ne:ge.buttonUp().then(function(){return he.sendServiceMsg({cmd:oe},t.source)})}});var ge={cursorElement:null,x:50,y:50,pointerOffsetX:0,pointerOffsetY:0,_createElement:function(){this.cursorElement=ql.createElement("div"),le.addClass(this.cursorElement,"cursor"),ce.isTouchDevice&&!ue.isIE&&(le.addClass(this.cursorElement,"touch"),this.pointerOffsetX=Math.ceil(de.getWidth(this.cursorElement)/2),this.pointerOffsetY=Math.ceil(de.getHeight(this.cursorElement)/2)),h.element().appendChild(this.cursorElement)},_ensureCursorElement:function(){return this.cursorElement||this._createElement(),!0},isVisible:function(){return this.cursorElement&&"hidden"!==de.get(this.cursorElement,"visibility")},hide:function(){this._ensureCursorElement()&&this.isVisible()&&de.set(this.cursorElement,"visibility","hidden")},show:function(){this._ensureCursorElement()&&de.set(this.cursorElement,"visibility","")},move:function(t){return this._ensureCursorElement()&&(this.x=t.x,this.y=t.y,de.set(this.cursorElement,{left:this.x-this.pointerOffsetX+"px",top:this.y-this.pointerOffsetY+"px"})),ae.resolve()},leftButtonDown:function(){return this._ensureCursorElement()&&(le.removeClass(this.cursorElement,ve),le.addClass(this.cursorElement,fe)),ae.resolve()},rightButtonDown:function(){return this._ensureCursorElement()&&(le.removeClass(this.cursorElement,ve),le.addClass(this.cursorElement,me)),ae.resolve()},buttonUp:function(){return this._ensureCursorElement()&&le.removeClass(this.cursorElement,ve),ae.resolve()}},ye=t.utils.browser.isIE?1:0,_e={move:function(t){var e={cmd:Zt,x:t.x+ye,y:t.y+ye};return c.sendRequestToFrame(e,ie,jl.parent)},leftButtonDown:function(){return c.sendRequestToFrame({cmd:te},re,jl.parent)},rightButtonDown:function(){return c.sendRequestToFrame({cmd:ee},se,jl.parent)},buttonUp:function(){return c.sendRequestToFrame({cmd:ne},oe,jl.parent)}},Ce={screenshotMark:null,_createMark:function(){this.screenshotMark=ql.createElement("img"),u.shadowUI.addClass(this.screenshotMark,"screenshot-mark"),this.screenshotMark.style.right=10/jl.devicePixelRatio+"px",this.screenshotMark.style.width=32/jl.devicePixelRatio+"px",this.screenshotMark.style.height=10/jl.devicePixelRatio+"px",this.hide(),u.shadowUI.getRoot().appendChild(this.screenshotMark)},hide:function(){this.screenshotMark&&(this.screenshotMark.style.visibility="hidden")},show:function(t){this.screenshotMark||this._createMark(),u.nativeMethods.imageSrcSetter.call(this.screenshotMark,t),this.screenshotMark.style.visibility=""}},be=t.shadowUI,Ee=t.nativeMethods;function we(t){var e=t.tag,n=void 0===e?"div":e,i=t.class,r=t.src,s=t.text,o=t.type,a=t.value,l=ql.createElement(n);return o&&Ee.setAttribute.call(l,"type",o),a&&Ee.inputValueSetter.call(l,a),r&&Ee.setAttribute.call(l,"src",r),i&&be.addClass(l,i),s&&Ee.nodeTextContentSetter.call(l,s),l}var Se=n.styleUtils;function Te(t,e){for(var n in e)Se.set(t,n,e[n])}var xe={tag:"input",type:"button",value:"Pick",class:"pick-button"},Ie={tag:"input",type:"text",class:"selector-input"},Ae={class:"match-indicator",text:"No Matching Elements"},Me={class:"expand-selector-list"},Be={class:"selector-input-container"},Ne={tag:"input",type:"button",value:"Copy"},Ue={class:"selectors-list"},Re={class:"selector-inspector-panel"},De={class:"element-frame"},ke={class:"tooltip"},Ve={class:"arrow"},Oe={tag:"input",type:"text",class:"auxiliary-input"};function Pe(t){var e;t.parentElement||(e=h.panelsContainer(),h.element().insertBefore(t,e))}function Fe(t){t.parentElement&&h.element().removeChild(t)}var $e,Le=jl["%testCafeCore%"],ze=function(t,e){void 0===e&&(e=!1),this.type=t,this.editable=e,this.disabled=void 0},He=(J(We,$e=ze),We);function We(t){return $e.call(this,t.toLowerCase(),!0)||this}var je={edited:"$edited$",byTagName:"$tagName$",byId:"id",byText:"$text$",byClassAttr:"class",byAttr:"$attr$",byTagTree:"$dom$"},qe=[new ze(je.byTagName),new ze(je.byId),new ze(je.byText),new ze(je.byClassAttr),new ze(je.byAttr),new ze(je.byTagTree)],Ge=je.byTagTree,Ye=Object.freeze({__proto__:null,CustomSelectorRule:He,DEFAULT_SELECTOR_RULES:qe,RULE_TYPE:je,SelectorRule:ze,UNSWITCHABLE_RULE_TYPE:Ge}),Xe=(Ke.prototype.concat=function(t){return t.type===this.type?new Ke(this.type,this.filter.concat(" ",t.filter)):null},Ke);function Ke(t,e){this.type=t,this.filter=e}var Je="index",Qe="tag",Ze="attr",tn=Le.domUtils,en=Le.arrayUtils;function nn(t,e){var n=tn.getElementIndexInParent(e,t),i=new Xe(Qe,tn.getTagName(t));return 0===n?[i]:[i,new Xe(Je,n)]}function rn(t,e){for(var n=t.parentElement,i=[];n;){if(n===e)return i;i.push(n),n=n.parentElement}return i}var sn=Le.domUtils,on=Le.arrayUtils,an=(Object.defineProperty(ln.prototype,"isCustom",{get:function(){return this.ancestorSelectorDescriptor?this.isCustomRule||this.ancestorSelectorDescriptor.isCustomRule:this.isCustomRule},enumerable:!1,configurable:!0}),ln.prototype._getStringArrayRepresentation=function(){return function(t){for(var e=[],n=0,i=t;n<i.length;n++){var r,s=i[n];0===on.indexOf(t,s)?e.push("Selector('".concat(s.filter,"')")):"text"===s.type?e.push(".withText('".concat(s.filter,"')")):s.type===Je?e.push(".nth(".concat(s.filter,")")):s.type===Qe?e.push(".find('".concat(s.filter,"')")):s.type===Ze&&(r=s.filter.attrValueRe?", ".concat(s.filter.attrValueRe):"",e.push(".withAttribute('".concat(s.filter.attrName,"'").concat(r,")")))}return e}(this._concatFilterOptions())},ln.prototype._addFilterByIndex=function(t){var e;1<t.length&&0!==(e=on.indexOf(t,this.element))&&this.filterOptions.push(new Xe(Je,e))},ln.prototype._concatFilterOptions=function(){var t=this.ancestorSelectorDescriptor,e=[];t&&(e=t._concatFilterOptions()),this.cssSelector&&e.push(new Xe(Qe,this.cssSelector));var n=on.concat(e,this.filterOptions);return on.reduce(n,function(t,e){if(e.type===Qe&&t.length){var n=t[t.length-1];if(n.type===Qe)return t[t.length-1]=n.concat(e),t}return t.push(e),t},[])},ln.prototype._getElements=function(){if(this.ruleType===je.byTagTree)return[this.element];var t=this.ancestorSelectorDescriptor?this.ancestorSelectorDescriptor.element:sn.findDocument(this.element),e=null;if(this.cssSelector)try{var n=jl.eval("(function(){return '".concat(this.cssSelector,"';})();")),e=on.from(t.querySelectorAll(n))}catch(t){return null}else e=[t];return 0===(e=e.length&&this.filter?this.filter(e):e).length||-1===on.indexOf(e,this.element)?[]:e},ln.createFromInstance=function(t,e){return new ln({ancestorSelectorDescriptor:e,cssSelector:t.cssSelector,element:t.element,filter:t.filter,filterOptions:[].concat(t.filterOptions||[]),isCustomRule:t.isCustomRule,ruleType:t.ruleType})},ln.prototype.makeUnique=function(){var t=this.ancestorSelectorDescriptor,e=t?t._getElements():[],n=!t||e?this._getElements():null;n&&(t&&t._addFilterByIndex(e),this._addFilterByIndex(n),this.stringArray=this._getStringArrayRepresentation())},ln);function ln(t){this.ruleType=t.ruleType,this.isCustomRule=t.isCustomRule,this.element=t.element,this.ancestorSelectorDescriptor=t.ancestorSelectorDescriptor,this.cssSelector=t.cssSelector,this.filterOptions=on.concat([],t.filterOptions||[]),this.filter=t.filter,this.stringArray=this._getStringArrayRepresentation()}var un=(cn.prototype._init=function(){},cn.prototype._shouldCreate=function(){throw new Error("Not implemented")},cn.prototype._getDescriptor=function(){throw new Error("Not implemented")},cn.prototype.create=function(t,e){return this.element=t,this._init(),this._shouldCreate(e)?this._getDescriptor(e):null},cn);function cn(t){this.type=t,this.element=null}var hn,dn=Le.domUtils,pn=/html|body/,fn=/header|footer|main/,mn=(J(vn,hn=un),vn.prototype._init=function(){this.tagName=dn.getTagName(this.element)},vn.prototype._shouldCreate=function(){return this.useTopLevelParents&&pn.test(this.tagName)||fn.test(this.tagName)},vn.prototype._getDescriptor=function(){return new an({ruleType:this.type,element:this.element,cssSelector:this.tagName})},vn);function vn(t){void 0===t&&(t=!0);var e=hn.call(this,je.byTagName)||this;return e.tagName="",e.useTopLevelParents=t,e}function gn(t){return t.replace(/\\/g,"\\\\\\$&").replace(/'/g,"\\\\\\$&").replace(/(\!|#|"|\$|%|&|\(|\||\)|\*|\+|,|\.|\/|:|;|<|=|>|\?|@|\[|\]|\^|`|{|\||}|~)/g,"\\\\$&")}function yn(t){return t.replace(/'|"|\\|\||\-|\*|\?|\+|\^|\$|\[|\]/g,"\\$&").replace(/\(|\)/g,"\\S")}var _n=jl["%hammerhead%"],Cn=/[\\^$*+?.()|[\]{}]/g,bn=Le.selectorAttributeFilter,En=Le.arrayUtils,wn=_n.nativeMethods;function Sn(t){return"string"==typeof t?new RegExp(t.replace(Cn,"\\$&")):t}var Tn=Le.domUtils,xn=Le.arrayUtils,In=/\$ctl\d+|ctl\d+\$|_ctl\d+|ctl\d+_|^ctl\d+$/g,An="!!!!!separator!!!!!",Mn="!!!!!anyNumber!!!!!",Bn=new RegExp(An,"g"),Nn=new RegExp(Mn,"g"),Un=/\s{2,}/g,Rn="class";function Dn(t,e,n,i,r){return new an({ancestorSelectorDescriptor:r,cssSelector:n,element:e,filter:(o=(s=i).attrName,a=s.attrValueRe,function(t){return En.filter(t,function(t){return bn(t,0,void 0,Sn(o),Sn(a))})}),filterOptions:new Xe(Ze,i),ruleType:t});var s,o,a}function kn(t,e,n,i){var r=Tn.getTagName(e),s="",o=null;return xn.forEach(n,function(t){var e=t.name,n=t.value,i=!1,r=!1;50<n.replace(Un," ").length&&(n=n.substr(0,50),i=!0),In.test(n)&&(r=!0,n=n.replace(In,function(t){return t.replace(/\d+/,Mn)})),Un.test(n)&&(r=!0,n=n.replace(Un,An)),r?o||(n=(n=yn(n)).replace(Nn,"\\d+").replace(Bn,"\\s+"),o={attrName:e,attrValueRe:new RegExp(n)}):(n=e===Rn?gn(n).trimEnd():n.replace(/\\/g,"\\\\\\$&").replace(/'/g,"\\\\\\$&").replace(/"/g,"\\\\$&"),s+=e!==Rn||i?"[".concat(e).concat(i?"^":"").concat(n?'="'.concat(n,'"'):"","]"):(" "+n).replace(/\s+/g,"."))}),o?Dn(t,e,s||r,o,i):new an({ruleType:t,element:e,ancestorSelectorDescriptor:i,cssSelector:s})}var Vn,On=Le.domUtils,Pn=/_ctl\d+|ctl\d+_|^ctl\d+$/g,Fn=(J($n,Vn=un),$n.prototype._init=function(){this.idAttr=this.element.getAttribute("id")},$n.prototype._shouldCreate=function(){return!!this.idAttr},$n.prototype._getDescriptor=function(){if(Pn.test(this.idAttr)){var t=(t=yn(this.idAttr)).replace(Pn,function(t){return t.replace(/\d+/,"\\d+")}),e=On.getTagName(this.element),n={attrName:"id",attrValueRe:new RegExp(t)};return Dn(je.byId,this.element,e,n)}return new an({ruleType:je.byId,element:this.element,cssSelector:"#"+gn(this.idAttr).replace(/\s/g,"\\\\ ")})},$n);function $n(){var t=Vn.call(this,je.byId)||this;return t.idAttr=null,t}var Ln=Le.domUtils,zn=_n.utils.trim,Hn=_n.nativeMethods,Wn=/^i$|^b$|^big$|^small$|^em$|^strong$|^dfn$|^code$|^samp$|^kbd$|^var$|^cite$|^abbr$|^acronym$|^sub$|^sup$|span$|^bdo$|^address$|^div$|^a$|^object$|^p$|^h\d$|^pre$|^q$|^ins$|^del$|^dt$|^dd$|^li$|^label$|^option$|^fieldset$|^legend$|^button$|^caption$|^td$|^th$|^title$/,jn=50,qn=/['"\\]/g,Gn=/\r?\n|\r/i;function Yn(t){t=t.trim().replace(qn,"\\$&");var e=Gn.exec(t),n=e?e.index:t.length;return zn(t.substring(0,Math.min(n,jn)))}var Xn,Kn=Le.domUtils,Jn=(J(Qn,Xn=un),Qn.prototype._init=function(){this.elementText=function(t){var e=Ln.isHtmlElement(t)?Hn.htmlElementInnerTextGetter.call(t):t.innerText;if(e)return Yn(e);if(Ln.isOptionElement(t)){var n=Hn.nodeTextContentGetter.call(t);return n?Yn(n):""}return""}(this.element)},Qn.prototype._shouldCreate=function(){return t=this.element,e=this.elementText,Wn.test(Ln.getTagName(t))?(e=zn(e.replace(/\s+/g," ")),/\S/.test(e)):"";var t,e},Qn.prototype._getDescriptor=function(){return new an({ruleType:this.type,element:this.element,cssSelector:Kn.getTagName(this.element),filterOptions:new Xe("text",this.elementText),filter:(e=this.elementText,function(t){return En.filter(t,function(t){return-1<(wn.htmlElementInnerTextGetter.call(t)||wn.nodeTextContentGetter.call(t)).indexOf(e)})})});var e},Qn);function Qn(){var t=Xn.call(this,je.byText)||this;return t.elementText="",t}var Zn=Le.domUtils,ti=Le.arrayUtils,ei=_n.nativeMethods,ni="%testcafe-stored-attributes%",ii=/(^alt$|^name$|^class$|^title$|^data-\S+)/,ri=/^data-ga\S+/;function si(t,e){void 0===e&&(e=[]);var n=t[ni];if(n)return ti.filter(n,function(t){return t.name!==Rn});for(var i,r=ei.elementAttributesGetter.call(t),s=[],o=0;o<r.length;o++)(i=r[o]).nodeName!==Rn&&function(t,e){void 0===e&&(e=[]);var n=t.nodeName;return t.nodeValue&&ii.test(n)&&-1===ti.indexOf(e,n)&&!ri.test(n)&&!Zn.isHammerheadAttr(n)}(i,e)&&s.push({name:i.nodeName,value:i.nodeValue});return s}var oi,ai=(J(li,oi=un),li.prototype._init=function(){this.elementAttributes=si(this.element,this.customAttrNames)},li.prototype._shouldCreate=function(){return!!this.elementAttributes.length},li.prototype._getDescriptor=function(){return kn(this.type,this.element,this.elementAttributes)},li);function li(t){void 0===t&&(t=[]);var e=oi.call(this,je.byAttr)||this;return e.customAttrNames=t,e.elementAttributes=[],e}var ui,ci=(J(hi,ui=un),hi.prototype._init=function(){this.className=function(t,e){for(var n,i=t[ni]||ei.elementAttributesGetter.call(t),r=0;r<i.length;r++)if((n=i[r]).name===e&&n.value)return n.value;return null}(this.element,Rn)},hi.prototype._shouldCreate=function(){return!!this.className},hi.prototype._getDescriptor=function(){return kn(this.type,this.element,[{name:Rn,value:this.className}])},hi);function hi(){var t=ui.call(this,je.byClassAttr)||this;return t.className="",t}var di,pi,fi=Le.domUtils,mi=Le.arrayUtils,vi=(J(gi,di=un),gi.prototype._shouldCreate=function(t){var e=t?t.element:fi.findDocument(this.element).body;return this.parents=rn(this.element,e),this.parents.push(e),this.parents.length},gi.prototype._getDescriptor=function(t){var e,n="",i=[];return e=this.element,/html|body/.test(tn.getTagName(e).toLowerCase())?i.push(new Xe(Qe,fi.getTagName(this.element))):i=function(t,e){for(var n=en.reverse(nn(t,e[0])),i=e.length,r=0;r<i-1;r++){var s=nn(e[r],e[r+1]),o=s[0],a=s[1];a&&n.push(a),n.push(o)}return en.reverse(n)}(this.element,this.parents),t?new an({ruleType:this.type,element:this.element,ancestorSelectorDescriptor:t,filterOptions:i}):(i.length&&(n=i[0].filter,mi.splice(i,0,1)),new an({ruleType:this.type,element:this.element,cssSelector:n,filterOptions:i}))},gi);function gi(){var t=di.call(this,je.byTagTree)||this;return t.parents=[],t}var yi,_i=((pi={})[je.byTagName]=new mn,pi[je.byId]=new Fn,pi[je.byText]=new Jn,pi[je.byClassAttr]=new ci,pi[je.byAttr]=new ai,pi[je.byTagTree]=new vi,pi),Ci=(J(bi,yi=un),bi.prototype._init=function(){var t=function(t,e){var n=t["%testcafe-custom-stored-attributes%"];if(n){var i=ti.find(n,function(t){return t.name===e});return i||null}return t.hasAttribute(e)?{name:e,value:t.getAttribute(e)}:null}(this.element,this.attrName);this.elementAttributes=t?[t]:[]},bi.prototype._shouldCreate=function(){return!!this.elementAttributes.length},bi.prototype._getDescriptor=function(){var t=kn(this.type,this.element,this.elementAttributes);return t.isCustomRule=!0,t},bi);function bi(t){var e=yi.call(this,t)||this;return e.attrName=t,e.elementAttributes=[],e}var Ei=Le.arrayUtils,wi=[je.byTagName,je.byId,je.byClassAttr,je.byAttr],Si=[je.byText,je.byClassAttr,je.byAttr,je.byTagTree];function Ti(t){return t.isCustomRule||-1!==Ei.indexOf(Si,t.ruleType)&&t.ruleType!==je.byTagTree}function xi(t){return t.editable||-1!==Ei.indexOf(wi,t.type)}var Ii=" > ";function Ai(t,e){return e?e+Ii+t:t}var Mi=1;function Bi(t){for(var e,n={},i=Mi,r=0,s=t;r<s.length;r++){var o=s[r];if(n[o.type]=i++,xi(o))for(var a=0,l=t;a<l.length;a++){var u=l[a];!(e=u).editable&&-1===Ei.indexOf(Si,e.type)||(n[Ai(u.type,o.type)]=i++)}}return n}var Ni=Le.domUtils,Ui=Le.arrayUtils;function Ri(t,e,n){for(var i=[],r=0,s=e;r<s.length;r++){var o=s[r].create(t,n);o&&i.push(o)}return i}function Di(t,e){for(var n=[],i=0,r=e;i<r.length;i++){var s=function(t,e){for(var n=0,i=t;n<i.length;n++){var r=i[n],s=e.create(r);if(s)return s}return null}(t,r[i]);s&&n.push(s)}return n}function ki(t){for(var n=[],e=0,i=t;e<i.length;e++){var r=i[e],s=function(e){return function(t,e){for(var n=t.length,i=0;i<n;i++)if(e(t[i]))return i;return-1}(n,function(t){return Ui.join(t.stringArray,"")===Ui.join(e.stringArray,"")})}(r);-1===s?n.push(r):n[s].priority>r.priority&&Ui.splice(n,s,1,r)}return n}function Vi(t){function e(t){return t&&t.ancestorSelectorDescriptor?t.ancestorSelectorDescriptor.ruleType:null}for(var n=Ui.filter(t,function(t){return!t.isCustom}),i=Ui.filter(n,function(t){return t.ancestorSelectorDescriptor}),r=i.length,s=10-(n.length-r),o=r-1;s<r;){for(var a=e(i[o]);e(i[o-1])===a&&(Ui.remove(t,i[o]),!(--r<=s));)o--;o--}}function Oi(t){void 0===t&&(t=qe),this.rules=Ui.filter(t,function(t){return!t.disabled});var e=Oi._processRules(this.rules),n=e.customRules,i=e.defaultRules;this.customRules=n,this.defaultRules=i,this.customAttrNames=[],this.customSelectorCreators=[],this.elementSelectorCreators=[],this.ancestorSelectorCreators=[],this._createCustomSelectorCreators(),this._createElementSelectorCreators(),this._createAncestorSelectorCreators(),this.rulePriority=Bi(this.rules)}var Pi=(Oi._priorityComparator=function(t,e){return t.priority-e.priority},Oi._getSelectorType=function(t){var e=t.ancestorSelectorDescriptor,n=e?e.ruleType:"";return Ai(t.ruleType,n)},Oi._processRules=function(t){var e=[],n=[];return Ui.filter(t,function(t){t.editable?n.push(t):e.push(t)}),{customRules:n,defaultRules:e}},Oi.prototype._createCustomSelectorCreators=function(){var e=this;Ui.forEach(this.customRules,function(t){e.customAttrNames.push(t.type),e.customSelectorCreators.push(new Ci(t.type))})},Oi.prototype._createElementSelectorCreators=function(){var n=this,i=[];Ui.forEach(this.defaultRules,function(t){var e=t.type===je.byAttr?new ai(n.customAttrNames):_i[t.type];i.push(e)}),this.elementSelectorCreators=Ui.concat(i,this.customSelectorCreators)},Oi.prototype._createAncestorSelectorCreators=function(){for(var t=0,e=this.customRules;t<e.length;t++){var n=e[t];this.ancestorSelectorCreators.push(new Ci(n.type))}for(var i=0,r=this.defaultRules;i<r.length;i++)xi(n=r[i])&&(n.type===je.byTagName?this.ancestorSelectorCreators.push(new mn(!1)):this.ancestorSelectorCreators.push(_i[n.type]))},Oi.prototype._generateCompoundSelectorDescriptor=function(t,e,n){for(var i=Ui.filter(n,Ti),r=[],s=null,o=null,a=0,l=Di(e,this.ancestorSelectorCreators);a<l.length;a++){for(var u=l[a],c=0,h=i;c<h.length;c++){var d=h[c],o=an.createFromInstance(u),s=an.createFromInstance(d,o);r.push(s)}o=an.createFromInstance(u),s=Ri(t,[_i[je.byTagTree]],u),r=Ui.concat(r,s)}return r},Oi.prototype._cleanAndSortDescriptors=function(t){for(var e=[],n=0,i=t;n<i.length;n++){var r=i[n];r.makeUnique();var s=Oi._getSelectorType(r),o=this.rulePriority[s];null!==o&&(r.priority=o,e.push(r))}return Vi(e=(e=ki(e)).sort(Oi._priorityComparator)),e},Oi.prototype._generateDescriptors=function(t){var e=Ri(t,this.elementSelectorCreators),n=rn(t,Ni.findDocument(t).body),i=this._generateCompoundSelectorDescriptor(t,n,e),r=Ui.concat(e,i);return this._cleanAndSortDescriptors(r)},Oi.prototype.generate=function(t){var e=this._generateDescriptors(t);return Ui.map(e,function(t){var e=t.stringArray,n=t.ruleType,i=t.ancestorSelectorDescriptor,r={value:Ui.join(e,""),rules:[n]};return i&&r.rules.push(i.ruleType),r})},Oi.RULES=Ye,new Oi);function Fi(){this.targets=new Map}var $i=(Fi.prototype._remove=function(t,e){this.targets.delete(t),Fe(e)},Fi.prototype._setPosition=function(t,e){for(var n,i,r,s=(n=t.getBoundingClientRect(),i=jl.pageYOffset||ql.documentElement.scrollTop,r=jl.pageXOffset||ql.documentElement.scrollLeft,{top:n.top+i,left:n.left+r,height:n.height,width:n.width,bottom:n.bottom+i,right:n.right+r}),o={},a=0,l=["top","left","width","height"];a<l.length;a++){var u=l[a];o[u]=s[u]+"px"}Te(e,o)},Fi.prototype.highlight=function(t){var e;t&&!this.targets.has(t)&&(e=we(De),this.targets.set(t,e),this._setPosition(t,e),Pe(e))},Fi.prototype.stopHighlighting=function(){var n=this;this.targets.forEach(function(t,e){return n._remove(e,t)})},new Fi),Li=t.nativeMethods;function zi(){this._createElements()}var Hi,Wi=(zi.prototype._createElements=function(){this.tooltip=we(ke),this.arrow=we(Ve)},zi.prototype._setTooltipText=function(t){Li.nodeTextContentSetter.call(this.tooltip,t)},zi.prototype._getTooltipLeft=function(t,e,n,i){return n<=t?i:n-e<=t?n+i-t:e+i},zi.prototype._getArrowLeft=function(t,e,n,i){return n-e<=t+12?n+i-t:e+i+12},zi.prototype._getVerticalPostionStyles=function(t,e,n,i){var r={},s={},o=ql.documentElement.scrollTop,a=t.height+e.height;return n.top>=a?(r.top=n.top+o-a+"px",s.top=n.top+o-e.height+"px",s.transform="none",s.visibility="visible"):i.height-n.bottom>=a?(r.top=n.bottom+o+e.height+"px",s.top=n.bottom+o+"px",s.transform="rotate(180deg)",s.visibility="visible"):(r.top=i.height+o-t.height+"px",s.top=o+"px",s.transform="node",s.visibility="hidden"),{tooltip:r,arrow:s}},zi.prototype._getElementsStyles=function(t){var e=this.tooltip.getBoundingClientRect(),n=this.arrow.getBoundingClientRect(),i=t.getBoundingClientRect(),r={width:ql.documentElement.clientWidth,height:ql.documentElement.clientHeight},s=this._getVerticalPostionStyles(e,n,i,r),o=ql.documentElement.scrollLeft;return s.tooltip.left=this._getTooltipLeft(e.width,i.left,r.width,o)+"px",s.arrow.left=this._getArrowLeft(n.width,i.left,r.width,o)+"px",s},zi.prototype._placeElements=function(t){var e=this._getElementsStyles(t);Te(this.tooltip,e.tooltip),Te(this.arrow,e.arrow)},zi.prototype.show=function(t,e){this._setTooltipText(t),this._placeElements(e),Pe(this.tooltip),Pe(this.arrow)},zi.prototype.hide=function(){Fe(this.tooltip),Fe(this.arrow)},new zi),ji=t.eventSandbox.listeners,qi=n.styleUtils,Gi=n.serviceUtils,Yi="element-piked";function Xi(){var t=Hi.call(this)||this;return t.hiddenTestCafeElements=new Map,t.handlers={onClick:t._getClickHandler(),onMouseMove:t._getMouseMoveHandler()},t}var Ki=(J(Xi,Hi=Gi.EventEmitter),Xi.prototype._hideTestCafeElements=function(){for(var t=0,e=h.element().children;t<e.length;t++){var n=e[t],i=qi.get(n,"visibility");this.hiddenTestCafeElements.set(n,i),qi.set(n,"visibility","hidden")}},Xi.prototype._showTestCafeElements=function(){this.hiddenTestCafeElements.forEach(function(t,e){qi.set(e,"visibility",t)}),this.hiddenTestCafeElements.clear()},Xi.prototype._getClickHandler=function(){var t=this;return function(){t._showTestCafeElements(),ji.removeInternalEventBeforeListener(jl,["mousemove"],t.handlers.onMouseMove),ji.removeInternalEventBeforeListener(jl,["click"],t.handlers.onClick),t.emit(Yi,t.actualSelectors),Wi.hide()}},Xi.prototype._getMouseMoveHandler=function(){var r=this;return function(t){var e=t.clientX,n=t.clientY,i=ql.elementFromPoint(e,n);i&&i!==r.actualTarget&&(r.actualTarget=i,r.actualSelectors=Pi.generate(i),$i.stopHighlighting(),$i.highlight(i),Wi.show(r.actualSelectors[0].value,i))}},Xi.prototype.start=function(t){this._hideTestCafeElements(),ji.initElementListening(jl,["mousemove","click"]),ji.addFirstInternalEventBeforeListener(jl,["mousemove"],this.handlers.onMouseMove),ji.addFirstInternalEventBeforeListener(jl,["click"],this.handlers.onClick),this.handlers.onMouseMove(t)},new Xi),Ji=n.eventUtils,Qi=function(){this.element=we(xe),Ji.bind(this.element,"click",function(t){return Ki.start(t)})};function Zi(t){return t}var tr,er=(function(t){function n(t){return!!o[t]}function i(t,e){this.references=t,this.transforms=e,this.circularCandidates=[],this.circularCandidatesDescrs=[],this.circularRefCount=0}var s=/^#*@(t|r)$/,r=(0,eval)("this"),o={Int8Array:"function"==typeof Int8Array?Int8Array:void 0,Uint8Array:"function"==typeof Uint8Array?Uint8Array:void 0,Uint8ClampedArray:"function"==typeof Uint8ClampedArray?Uint8ClampedArray:void 0,Int16Array:"function"==typeof Int16Array?Int16Array:void 0,Uint16Array:"function"==typeof Uint16Array?Uint16Array:void 0,Int32Array:"function"==typeof Int32Array?Int32Array:void 0,Uint32Array:"function"==typeof Uint32Array?Uint32Array:void 0,Float32Array:"function"==typeof Float32Array?Float32Array:void 0,Float64Array:"function"==typeof Float64Array?Float64Array:void 0},a="function"==typeof ArrayBuffer,l="function"==typeof Map,u="function"==typeof Set,c="function"==typeof Buffer,h=Array.prototype.slice,e={serialize:function(t){return JSON.stringify(t)},deserialize:function(t){return JSON.parse(t)}};function d(t,e){this.references=t,this.transformMap=e,this.activeTransformsStack=[],this.visitedRefs=Object.create(null)}i._createRefMark=function(t){var e=Object.create(null);return e["@r"]=t,e},i.prototype._createCircularCandidate=function(t,e,n){this.circularCandidates.push(t),this.circularCandidatesDescrs.push({parent:e,key:n,refIdx:-1})},i.prototype._applyTransform=function(t,e,n,i){var r=Object.create(null),s=i.toSerializable(t);return"object"==typeof s&&this._createCircularCandidate(t,e,n),r["@t"]=i.type,r.data=this._handleValue(s,e,n),r},i.prototype._handleArray=function(t){for(var e=[],n=0;n<t.length;n++)e[n]=this._handleValue(t[n],e,n);return e},i.prototype._handlePlainObject=function(n){var i=this,r=Object.create(null);return Object.getOwnPropertyNames(n).forEach(function(t){var e=s.test(t)?"#"+t:t;r[e]=i._handleValue(n[t],r,e)}),r},i.prototype._handleObject=function(t,e,n){return this._createCircularCandidate(t,e,n),Array.isArray(t)?this._handleArray(t):this._handlePlainObject(t)},i.prototype._ensureCircularReference=function(t){var e=this.circularCandidates.indexOf(t);if(-1<e){var n=this.circularCandidatesDescrs[e];return-1===n.refIdx&&(n.refIdx=n.parent?++this.circularRefCount:0),i._createRefMark(n.refIdx)}return null},i.prototype._handleValue=function(t,e,n){var i=typeof t,r="object"==i&&null!==t;if(r){var s=this._ensureCircularReference(t);if(s)return s}for(var o=0;o<this.transforms.length;o++){var a=this.transforms[o];if(a.shouldTransform(i,t))return this._applyTransform(t,e,n,a)}return r?this._handleObject(t,e,n):t},i.prototype.transform=function(){for(var t=[this._handleValue(this.references,null,null)],e=0;e<this.circularCandidatesDescrs.length;e++){var n=this.circularCandidatesDescrs[e];0<n.refIdx&&(t[n.refIdx]=n.parent[n.key],n.parent[n.key]=i._createRefMark(n.refIdx))}return t},d.prototype._handlePlainObject=function(e){var t,n=this,i=Object.create(null),r=Object.getOwnPropertyNames(e);for(t in r.forEach(function(t){n._handleValue(e[t],e,t),s.test(t)&&(i[t.substring(1)]=e[t],delete e[t])}),i)e[t]=i[t]},d.prototype._handleTransformedObject=function(t,e,n){var i=t["@t"],r=this.transformMap[i];if(!r)throw new Error("Can't find transform for \""+i+'" type.');this.activeTransformsStack.push(t),this._handleValue(t.data,t,"data"),this.activeTransformsStack.pop(),e[n]=r.fromSerializable(t.data)},d.prototype._handleCircularSelfRefDuringTransform=function(t,e,n){var i=this.references,r=void 0;Object.defineProperty(e,n,{configurable:!0,enumerable:!0,get:function(){return void 0===r&&(r=i[t]),r},set:function(t){return r=t}})},d.prototype._handleCircularRef=function(t,e,n){-1<this.activeTransformsStack.indexOf(this.references[t])?this._handleCircularSelfRefDuringTransform(t,e,n):(this.visitedRefs[t]||(this.visitedRefs[t]=!0,this._handleValue(this.references[t],this.references,t)),e[n]=this.references[t])},d.prototype._handleValue=function(t,e,n){if("object"==typeof t&&null!==t){var i=t["@r"];if(void 0!==i)this._handleCircularRef(i,e,n);else if(t["@t"])this._handleTransformedObject(t,e,n);else if(Array.isArray(t))for(var r=0;r<t.length;r++)this._handleValue(t[r],t,r);else this._handlePlainObject(t)}},d.prototype.transform=function(){return this.visitedRefs[0]=!0,this._handleValue(this.references[0],this.references,0),this.references[0]};var p=[{type:"[[NaN]]",shouldTransform:function(t,e){return"number"===t&&isNaN(e)},toSerializable:function(){return""},fromSerializable:function(){return NaN}},{type:"[[undefined]]",shouldTransform:function(t){return"undefined"===t},toSerializable:function(){return""},fromSerializable:function(){}},{type:"[[Date]]",shouldTransform:function(t,e){return e instanceof Date},toSerializable:function(t){return t.getTime()},fromSerializable:function(t){var e=new Date;return e.setTime(t),e}},{type:"[[RegExp]]",shouldTransform:function(t,e){return e instanceof RegExp},toSerializable:function(t){var e={src:t.source,flags:""};return t.global&&(e.flags+="g"),t.ignoreCase&&(e.flags+="i"),t.multiline&&(e.flags+="m"),e},fromSerializable:function(t){return new RegExp(t.src,t.flags)}},{type:"[[Error]]",shouldTransform:function(t,e){return e instanceof Error},toSerializable:function(t){return{name:t.name,message:t.message,stack:t.stack}},fromSerializable:function(t){var e=new(r[t.name]||Error)(t.message);return e.stack=t.stack,e}},{type:"[[ArrayBuffer]]",shouldTransform:function(t,e){return a&&e instanceof ArrayBuffer},toSerializable:function(t){var e=new Int8Array(t);return h.call(e)},fromSerializable:function(t){if(a){var e=new ArrayBuffer(t.length);return new Int8Array(e).set(t),e}return t}},{type:"[[Buffer]]",shouldTransform:function(t,e){return c&&e instanceof Buffer},toSerializable:function(t){return h.call(t)},fromSerializable:function(t){return c?Buffer.from(t):t}},{type:"[[TypedArray]]",shouldTransform:function(t,e){return Object.keys(o).some(function(t){return n(t)&&e instanceof o[t]})},toSerializable:function(t){return{ctorName:t.constructor.name,arr:h.call(t)}},fromSerializable:function(t){return n(t.ctorName)?new o[t.ctorName](t.arr):t.arr}},{type:"[[Map]]",shouldTransform:function(t,e){return l&&e instanceof Map},toSerializable:function(t){var n=[];return t.forEach(function(t,e){n.push(e),n.push(t)}),n},fromSerializable:function(t){if(l){for(var e=new Map,n=0;n<t.length;n+=2)e.set(t[n],t[n+1]);return e}for(var i=[],r=0;r<t.length;r+=2)i.push([t[n],t[n+1]]);return i}},{type:"[[Set]]",shouldTransform:function(t,e){return u&&e instanceof Set},toSerializable:function(t){var e=[];return t.forEach(function(t){e.push(t)}),e},fromSerializable:function(t){if(u){for(var e=new Set,n=0;n<t.length;n++)e.add(t[n]);return e}return t}}],f=t.exports=function(t){this.transforms=[],this.transformsMap=Object.create(null),this.serializer=t||e,this.addTransforms(p)};f.prototype.addTransforms=function(t){t=Array.isArray(t)?t:[t];for(var e=0;e<t.length;e++){var n=t[e];if(this.transformsMap[n.type])throw new Error('Transform with type "'+n.type+'" was already added.');this.transforms.push(n),this.transformsMap[n.type]=n}return this},f.prototype.removeTransforms=function(t){t=Array.isArray(t)?t:[t];for(var e=0;e<t.length;e++){var n=t[e],i=this.transforms.indexOf(n);-1<i&&this.transforms.splice(i,1),delete this.transformsMap[n.type]}return this},f.prototype.encode=function(t){var e=new i(t,this.transforms).transform();return this.serializer.serialize(e)},f.prototype.decode=function(t){var e=this.serializer.deserialize(t);return new d(e,this.transformsMap).transform()}}(tr={exports:{}}),tr.exports);function nr(t){return new er({serialize:Zi,deserialize:Zi}).addTransforms(t)}function ir(t,e){this.code=t,this.isTestCafeError=!0,this.callsite=e||null}var rr,sr,or="E1",ar="E4",lr="E5",ur="E9",cr="E10",hr="E11",dr="E12",pr="E24",fr="E26",mr="E27",vr="E28",gr="E29",yr="E30",_r="E31",Cr="E32",br="E33",Er="E34",wr="E35",Sr="E36",Tr="E37",xr="E39",Ir="E40",Ar="E41",Mr="E42",Br="E43",Nr="E44",Ur="E45",Rr="E46",Dr="E49",kr="E50",Vr="E51",Or="E52",Pr="E57",Fr="E64",$r="E65",Lr="E68",zr="E69",Hr="E70",Wr="E71",jr="E72",qr="E73",Gr="E74",Yr="E76",Xr="E77",Kr="E78",Jr="E82",Qr="E83",Zr="E90",ts="E91",es="E92",ns="E93",is="E94",rs="E95",ss="E97",os="E99",as="E100",ls="E101",us="E102",cs=(J(hs,rr=ir),hs);function hs(t,e,n){var i=rr.call(this,t)||this;return i.optionName=e,i.actualValue=n,i}function ds(t,e){var n=sr.call(this,Dr,e)||this;return n.instantiationCallsiteName=t,n}J(ds,sr=ir);var ps,fs=(J(ms,ps=ir),ms);function ms(t,e){var n=ps.call(this,kr,e)||this;return n.instantiationCallsiteName=t,n}var vs,gs=(J(ys,vs=ir),ys);function ys(t,e,n){var i=void 0===e?{}:e,r=i.apiFnChain,s=i.apiFnIndex,o=i.reason,a=vs.call(this,t,n)||this;return a.apiFnChain=r,a.apiFnIndex=s,a.reason=o,a}var _s,Cs,bs,Es=(J(ws,_s=ir),ws);function ws(t){return _s.call(this,Vr,t)||this}function Ss(t,e){return Cs.call(this,Or,e,t)||this}function Ts(t,e){var n=bs.call(this,or)||this;return n.errStack=t,n.pageDestUrl=e,n}J(Ss,Cs=gs),J(Ts,bs=ir);var xs,Is=(J(As,xs=ir),As);function As(t,e,n){var i=xs.call(this,ar,n)||this;return i.errMsg=String(e),i.instantiationCallsiteName=t,i}var Ms,Bs,Ns,Us,Rs,Ds,ks,Vs,Os,Ps,Fs,$s,Ls,zs,Hs,Ws,js,qs,Gs,Ys,Xs,Ks,Js,Qs,Zs,to,eo,no,io,ro,so,oo,ao,lo,uo,co,ho,po,fo,mo,vo,go,yo,_o,Co,bo,Eo,wo,So,To,xo,Io,Ao,Mo=(J(Bo,Ms=ir),Bo);function Bo(t,e,n,i){var r=Ms.call(this,lr,i)||this;return r.errMsg=String(e),r.property=n,r.instantiationCallsiteName=t,r}function No(t){var e=Bs.call(this,Fr)||this;return e.errMsg=String(t),e}function Uo(t,e){var n=Ns.call(this,$r)||this;return n.errMsg=String(t),n.moduleName=e,n}function Ro(t,e){return Us.call(this,ur,t,e)||this}function Do(t,e){return Rs.call(this,cr,t,e)||this}function ko(t,e){return Ds.call(this,hr,t,e)||this}function Vo(t,e){return ks.call(this,dr,t,e)||this}function Oo(t,e){return Vs.call(this,Zr,t,e)||this}function Po(t,e){return Os.call(this,ss,t,e)||this}function Fo(t,e){return Ps.call(this,ts,t,e)||this}function $o(t,e){return Fs.call(this,es,t,e)||this}function Lo(t,e){return $s.call(this,ns,t,e)||this}function zo(t,e){return Ls.call(this,is,t,e)||this}function Ho(t,e){return zs.call(this,rs,t,e)||this}function Wo(t,e){return Hs.call(this,os,t,e)||this}function jo(t,e,n){var i=Ws.call(this,as)||this;return i.objectName=t,i.propertyName=e,i.availableProperties=n,i}function qo(t,e){return js.call(this,pr,e,t)||this}function Go(t,e){return qs.call(this,fr,e,t)||this}function Yo(t){var e=Gs.call(this,mr)||this;return e.nodeDescription=t,e}function Xo(t,e){var n=Ys.call(this,vr,e)||this;return n.argumentName=t,n}function Ko(t){return Xs.call(this,ls,t)||this}function Jo(t,e){var n=Ks.call(this,gr,e)||this;return n.argumentName=t,n}function Qo(t,e){var n=Js.call(this,yr)||this;return n.argumentName=t,n.nodeDescription=e,n}function Zo(){return Qs.call(this,_r)||this}function ta(){return Zs.call(this,Cr)||this}function ea(t){var e=to.call(this,br)||this;return e.argumentName=t,e}function na(){return eo.call(this,wr)||this}function ia(t){var e=no.call(this,Sr)||this;return e.argumentName=t,e}function ra(t,e){var n=io.call(this,Tr)||this;return n.filePaths=t,n.scannedFilePaths=e,n}function sa(){return ro.call(this,Er)||this}function oa(t,e){var n=so.call(this,Ar)||this;return n.properties=t?"scrollTargetY property":e?"scrollTargetX property":"scrollTargetX and scrollTargetY properties",n}function aa(t,e){var n=oo.call(this,Pr)||this;return t<=0?e<=0?(n.verb="are",n.dimensions="width and height"):(n.verb="is",n.dimensions="width"):(n.verb="is",n.dimensions="height"),n}function la(t){return ao.call(this,Ir,t)||this}function ua(){return lo.call(this,xr)||this}function ca(){return uo.call(this,Mr)||this}function ha(){return co.call(this,zr)||this}function da(){return ho.call(this,Lr)||this}function pa(){return po.call(this,Hr)||this}function fa(){return fo.call(this,Wr)||this}function ma(){return mo.call(this,qr)||this}function va(){return vo.call(this,Jr)||this}function ga(t){var e=go.call(this,Kr)||this;return e.errMsg=t,e}function ya(){return yo.call(this,Gr)||this}function _a(){return _o.call(this,Yr)||this}function Ca(){return Co.call(this,Xr)||this}function ba(){return bo.call(this,jr)||this}function Ea(){return Eo.call(this,Qr)||this}function wa(){return wo.call(this,Br)||this}function Sa(){return So.call(this,Nr)||this}function Ta(t,e){var n=To.call(this,Ur)||this;return n.dialogType=t,n.pageUrl=e,n}function xa(t,e,n){var i=xo.call(this,Rr)||this;return i.dialogType=t,i.errMsg=e,i.pageUrl=n,i}function Ia(){return Io.call(this,us)||this}J(No,Bs=ir),J(Uo,Ns=ir),J(Ro,Us=cs),J(Do,Rs=cs),J(ko,Ds=cs),J(Vo,ks=cs),J(Oo,Vs=cs),J(Po,Os=cs),J(Fo,Ps=cs),J($o,Fs=cs),J(Lo,$s=cs),J(zo,Ls=cs),J(Ho,zs=cs),J(Wo,Hs=cs),J(jo,Ws=ir),J(qo,js=gs),J(Go,qs=gs),J(Yo,Gs=ir),J(Xo,Ys=gs),J(Ko,Xs=ir),J(Jo,Ks=gs),J(Qo,Js=ir),J(Zo,Qs=ir),J(ta,Zs=ir),J(ea,to=ir),J(na,eo=ir),J(ia,no=ir),J(ra,io=ir),J(sa,ro=ir),J(oa,so=ir),J(aa,oo=ir),J(la,ao=ir),J(ua,lo=ir),J(ca,uo=ir),J(ha,co=ir),J(da,ho=ir),J(pa,po=ir),J(fa,fo=ir),J(ma,mo=ir),J(va,vo=ir),J(ga,go=ir),J(ya,yo=ir),J(_a,_o=ir),J(Ca,Co=ir),J(ba,bo=ir),J(Ea,Eo=ir),J(wa,wo=ir),J(Sa,So=ir),J(Ta,To=ir),J(xa,xo=ir),J(Ia,Io=ir);var Aa=1,Ma=2,Ba=3,Na=((Ao={})[Aa]=/^\.filterVisible\(\)$/,Ao[Ma]=/^\.filterHidden\(\)$/,Ao[Ba]=/^\.nth\(\d+\)$/,Ao);function Ua(){this._err=null}var Ra=(Object.defineProperty(Ua.prototype,"error",{get:function(){return this._err},set:function(t){null===this._err&&(this._err=t)},enumerable:!1,configurable:!0}),Ua.prototype.filter=function(t,e,n){if(e.filterVisible&&(t=t.filter(c.positionUtils.isElementVisible),this._assertFilterError(t,n,Aa)),e.filterHidden&&(t=t.filter(function(t){return!c.positionUtils.isElementVisible(t)}),this._assertFilterError(t,n,Ma)),e.counterMode)return null===e.index?t.length:Ua._getNodeByIndex(t,e.index)?1:0;var i;if(e.collectionMode)return null!==e.index&&(t=(i=Ua._getNodeByIndex(t,e.index))?[i]:[],this._assertFilterError(t,n,Ba)),t;var r=Ua._getNodeByIndex(t,e.index||0);return r||(this.error=Ua._getErrorItem(n,Ba)),r},Ua.prototype.cast=function(t){if(null==t)return[];if(t instanceof u.nativeMethods.Node)return[t];if(function(t){if(u.nativeMethods.isArray(t)){for(var e=0;e<t.length;e++)if(!(t[e]instanceof u.nativeMethods.Node))return;return 1}}(t))return t;if((e=t)instanceof u.nativeMethods.HTMLCollection||e instanceof u.nativeMethods.NodeList)return function(t){for(var e=t.length,n=[],i=0;i<e;i++)n.push(t[i]);return n}(t);var e;throw new Es},Ua.prototype._assertFilterError=function(t,e,n){0===t.length&&(this.error=Ua._getErrorItem(e,n))},Ua._getErrorItem=function(t,e){var n=t.apiFnChain,i=t.apiFnID;if(e)for(var r=i;r<n.length;r++)if(Na[e].test(n[r]))return r;return null},Ua._getNodeByIndex=function(t,e){return e<0?t[t.length+e]:t[e]},new Ua);function Da(t,e){return new u.nativeMethods.Function("fnCode","__dependencies$","Promise","RegExp",'"use strict"; return eval(fnCode)')(t,e,u.Promise,RegExp)}var ka=(Va.prototype.shouldTransform=function(t){return"function"===t},Va.prototype.toSerializable=function(){return""},Va.prototype.fromSerializable=function(t){var e=t.fnCode,n=t.dependencies;return"filterOptions"in n&&(n.selectorFilter=Ra),Da(e,n)},Va);function Va(){this.type="Function"}var Oa=(Pa.prototype.shouldTransform=function(t,e){if(e instanceof u.nativeMethods.Node)throw new fs(this._instantiationCallsiteName);return!1},Pa.prototype.toSerializable=function(){},Pa.prototype.fromSerializable=function(){},Pa);function Pa(t){this.type="Node",this._instantiationCallsiteName=t}var Fa=($a.prototype.getResult=function(){var e=this;return u.Promise.resolve().then(function(){var t=e.replicator.decode(e.command.args);return e._executeFn(t)}).catch(function(t){throw t.isTestCafeError||(t=new Is(e.command.instantiationCallsiteName,t)),t})},$a.prototype.encodeResult=function(t){return this.replicator.encode(t)},$a.prototype._createReplicator=function(){return nr([new Oa(this.command.instantiationCallsiteName),new ka])},$a.prototype._executeFn=function(t){return this.fn.apply(jl,t)},$a);function $a(t){this.command=t,this.replicator=this._createReplicator(),this.dependencies=this.replicator.decode(t.dependencies),this.fn=Da(t.fnCode,this.dependencies)}var La=["nodeType","textContent","childNodeCount","hasChildNodes","childElementCount","hasChildElements"],za=["tagName","attributes"],Ha=["tagName","visible","focused","attributes","boundingClientRect","classNames","style","innerText","namespaceURI","id","value","checked","selected","selectedIndex","scrollWidth","scrollHeight","scrollLeft","scrollTop","offsetWidth","offsetHeight","offsetLeft","offsetTop","clientWidth","clientHeight","clientLeft","clientTop"],Wa={childNodeCount:function(t){return t.childNodes.length},hasChildNodes:function(t){return!!Wa.childNodeCount(t)},childElementCount:function(t){var e=t.children;if(e)return e.length;for(var n=0,i=t.childNodes.length,r=0;r<i;r++)1===t.childNodes[r].nodeType&&n++;return n},hasChildElements:function(t){return!!Wa.childElementCount(t)}},ja=(qa.prototype._initializeProperties=function(t,e,n){for(var i=0,r=e;i<r.length;i++){var s=r[i],o=n[s];this[s]=o?o(t):t[s]}},qa);function qa(){}var Ga,Ya=(J(Xa,Ga=ja),Xa);function Xa(t){var e=Ga.call(this)||this;return e._initializeProperties(t,La,Wa),e}var Ka,Ja={tagName:function(t){return t.tagName.toLowerCase()},visible:function(t){return c.positionUtils.isElementVisible(t)},focused:function(t){return u.utils.dom.getActiveElement()===t},attributes:function(t){for(var e=t.attributes,n={},i=e.length-1;0<=i;i--)n[e[i].name]=e[i].value;return n},boundingClientRect:function(t){var e=t.getBoundingClientRect();return{left:e.left,right:e.right,top:e.top,bottom:e.bottom,width:e.width,height:e.height}},classNames:function(t){var e=t.className;return"string"==typeof e.animVal&&(e=e.animVal),e.replace(/^\s+|\s+$/g,"").split(/\s+/g)},style:function(t){for(var e={},n=jl.getComputedStyle(t),i=0;i<n.length;i++){var r=n[i];e[r]=n[r]}return e},innerText:function(t){return t.innerText}};function Qa(t){var e=Ka.call(this)||this;return e._initializeProperties(t,za,Ja),e}J(Qa,Ka=ja);var Za,tl=(J(el,Za=Ya),el);function el(t){var e=Za.call(this,t)||this;return e._initializeProperties(t,Ha,Ja),e}var nl=(il.prototype._extend=function(t,e){for(var n=0,i=u.nativeMethods.objectKeys(this._customDOMProperties);n<i.length;n++){var r=i[n];try{t[r]=this._customDOMProperties[r](e)}catch(t){throw new Mo(this._instantiationCallsiteName,t,r)}}},il.prototype.shouldTransform=function(t,e){return e instanceof u.nativeMethods.Node},il.prototype.toSerializable=function(t){var e=new(1===t.nodeType?tl:Ya)(t);return this._extend(e,t),e},il.prototype.fromSerializable=function(){},il);function il(t,e){void 0===t&&(t={}),this.type="Node",this._customDOMProperties=t,this._instantiationCallsiteName=e}var rl,sl=(J(ol,rl=Fa),ol.prototype._createReplicator=function(){return nr([new ka])},ol.prototype._getTimeoutErrorParams=function(t){return{apiFnIndex:Ra.error,apiFnChain:this.command.apiFnChain,reason:c.positionUtils.getHiddenReason(t)}},ol.prototype._getTimeoutError=function(t){return t?this.createIsInvisibleError:this.createNotFoundError},ol.prototype._validateElement=function(o,a){var l=this;return u.Promise.resolve().then(function(){return rl.prototype._executeFn.call(l,o)}).then(function(t){var e=t,n=!!e,i=!l.command.visibilityCheck||e&&c.positionUtils.isElementVisible(e),r=u.nativeMethods.dateNow()-a>=l.timeout;if(n&&(i||u.utils.dom.isShadowRoot(e)))return e;if(!r)return c.delay(200).then(function(){return l._validateElement(o,a)});var s=l.getVisibleValueMode?null:l._getTimeoutError(n);if(s)throw s(l._getTimeoutErrorParams(e));return null})},ol.prototype._executeFn=function(t){return this.counterMode?rl.prototype._executeFn.call(this,t):this._validateElement(t,u.nativeMethods.dateNow())},ol);function ol(t,e,n,i,r){var s,o=rl.call(this,t)||this;o.createNotFoundError=i,o.createIsInvisibleError=r,o.timeout="number"==typeof t.timeout?t.timeout:e,o.counterMode=o.dependencies.filterOptions.counterMode,o.getVisibleValueMode=o.dependencies.filterOptions.getVisibleValueMode,o.dependencies.selectorFilter=Ra,n&&(s=u.nativeMethods.dateNow()-n,o.timeout=Math.max(o.timeout-s,0));var a=o.dependencies.customDOMProperties;return o.replicator.addTransforms([new nl(a,t.instantiationCallsiteName)]),o}var al={testCafeDriver:"%testCafeDriver%",testCafeIframeDriver:"%testCafeIframeDriver%",testCafeEmbeddingUtils:"%testCafeEmbeddingUtils%",testCafeDriverInstance:"%testCafeDriverInstance%"},ll=5e3;function ul(){return null}function cl(){return null}function hl(e){return Q(this,void 0,void 0,function(){return Z(this,function(t){switch(t.label){case 0:return[4,function(n){return Q(this,void 0,void 0,function(){var e;return Z(this,function(t){return e=jl[al.testCafeDriverInstance].communicationUrls,[2,c.browser.parseSelector(e.parseSelector,u.createNativeXHR,n)]})})}(e)];case 1:return[2,function(n){return Q(this,void 0,void 0,function(){var e;return Z(this,function(t){switch(t.label){case 0:return e=u.nativeMethods.date(),[4,new sl(n,ll,e,ul,cl).getResult()];case 1:return[2,t.sent()]}})})}(t.sent()).catch(function(){return null})]}})})}var dl,pl=t.eventSandbox.listeners,fl=n.serviceUtils,ml="list-changed",vl="selector-selected";function gl(){var e=dl.call(this)||this;return e._pickedSelectors=[],e.element=we(Ue),Ki.on(Yi,function(t){e.pickedSelectors=t}),e}var yl=(J(gl,dl=fl.EventEmitter),Object.defineProperty(gl.prototype,"pickedSelectors",{get:function(){return this._pickedSelectors},set:function(t){void 0===t&&(t=[]),this._pickedSelectors!==t&&(this._pickedSelectors=t,this.emit(ml,t))},enumerable:!1,configurable:!0}),gl.prototype._renderSelectors=function(){var n=this;this.pickedSelectors.forEach(function(t){var e=we({text:t.value,class:"selector-value"});n.element.appendChild(e)}),this.renderedSelectors=this.pickedSelectors},gl.prototype._clear=function(){for(;this.element.firstChild;)this.element.removeChild(this.element.firstChild);this.renderedSelectors=null},gl.prototype._addClickListener=function(){var e=this,n=function(t){Fe(e.element),t.target.parentElement===e.element&&e.emit(vl,t.target.innerText),pl.removeInternalEventBeforeListener(jl,["click"],n)};pl.addFirstInternalEventBeforeListener(jl,["click"],n)},gl.prototype.show=function(t){var e,n=t.left,i=t.bottom,r=t.width;this.pickedSelectors&&0!==this.pickedSelectors.length&&(this.pickedSelectors!==this.renderedSelectors&&(this._clear(),this._renderSelectors()),e={left:n+"px",bottom:i+"px",width:r+"px"},Pe(this.element),Te(this.element,e),this._addClickListener())},gl.prototype.clear=function(){this.pickedSelectors=null},new gl),_l=t.nativeMethods,Cl=t.shadowUI,bl=n.eventUtils,El="enabled",wl={notFound:"not-found",invalid:"invalid",ok:"ok"},Sl=(Object.defineProperty(Tl.prototype,"value",{get:function(){return _l.inputValueGetter.call(this.input)},set:function(t){_l.inputValueSetter.call(this.input,t)},enumerable:!1,configurable:!0}),Tl.prototype._createElements=function(){this.element=we(Be),this.input=we(Ie),this.indicator=we(Ae),this.expandButton=we(Me),this.element.appendChild(this.input),this.element.appendChild(this.indicator),this.element.appendChild(this.expandButton)},Tl.prototype._addEventListeners=function(){var e=this;bl.bind(this.expandButton,"click",function(){return e._expandSelectorsList()}),bl.bind(this.input,"input",function(){return e._onSelectorTyped()}),bl.bind(this.input,"focus",function(){return e._onFocusInput()}),bl.bind(this.input,"blur",function(){return $i.stopHighlighting()}),yl.on(ml,function(t){e._updateExpandButton(t)}),yl.on(vl,function(t){e._setSelectorInputValue({value:t})}),Ki.on(Yi,function(t){e._setSelectorInputValue(t[0])})},Tl.prototype._setMatchIndicatorText=function(t){_l.nodeTextContentSetter.call(this.indicator,t)},Tl.prototype._setMatchIndicatorClass=function(t){for(var e in wl)Cl.removeClass(this.indicator,wl[e]);Cl.addClass(this.indicator,t)},Tl.prototype._indicateMatches=function(t){return null===t?(this._setMatchIndicatorText("Invalid Selector"),void this._setMatchIndicatorClass(wl.invalid)):0===t.length?(this._setMatchIndicatorText("No Matching Elements"),void this._setMatchIndicatorClass(wl.notFound)):(this._setMatchIndicatorText("Found: ".concat(t.length)),void this._setMatchIndicatorClass(wl.ok))},Tl.prototype._highlightElements=function(t){for(var e=0,n=t;e<n.length;e++){var i=n[e];$i.highlight(i)}},Tl.prototype._setSelectorInputValue=function(t){this.value=t.value,this.input.focus()},Tl.prototype._expandSelectorsList=function(){var t=this.element.getBoundingClientRect(),e=t.left,n=t.top,i={left:e,width:t.width,bottom:ql.documentElement.clientHeight-n+1};yl.show(i)},Tl.prototype._updateExpandButton=function(t){t&&t.length?Cl.addClass(this.expandButton,El):Cl.removeClass(this.expandButton,El)},Tl.prototype._onSelectorTyped=function(){yl.clear(),this._onFocusInput()},Tl.prototype._onFocusInput=function(){return Q(this,void 0,void 0,function(){var e;return Z(this,function(t){switch(t.label){case 0:return $i.stopHighlighting(),this.value?[4,hl(this.value)]:(this._indicateMatches([]),[2]);case 1:return e=t.sent(),this._indicateMatches(e),this._highlightElements(e),[2]}})})},Tl);function Tl(){this._createElements(),this._addEventListeners()}var xl=t.nativeMethods,Il=n.eventUtils,Al="Copy",Ml="Copied!",Bl=(Nl.prototype._copySelector=function(){var t,e;t=this.sourceElement.value,Pe(e=we(Oe)),e.value=t,e.select(),ql.execCommand("copy"),Fe(e),this._animate()},Nl.prototype._animate=function(){var t=this;this._changeAppearance(Ml,"bold"),xl.setTimeout.call(jl,function(){return t._resetAppearance()},1200)},Nl.prototype._resetAppearance=function(){this._changeAppearance(Al,"")},Nl.prototype._changeAppearance=function(t,e){xl.inputValueSetter.call(this.element,t),Te(this.element,{fontWeight:e})},Nl);function Nl(t){var e=this;this.element=we(Ne),this.sourceElement=t,Il.bind(this.element,"click",function(){return e._copySelector()})}var Ul=(Rl.prototype.show=function(){this.element.parentElement||h.insertFirstChildToPanelsContainer(this.element),Te(this.element,{display:"flex"})},Rl.prototype.hide=function(){Te(this.element,{display:"none"})},Rl);function Rl(){this.elementPicker=Ki,this.element=we(Re);var t=new Qi,e=new Sl,n=new Bl(e);this.element.appendChild(t.element),this.element.appendChild(e.element),this.element.appendChild(n.element)}var Dl=t.Promise,kl=t.eventSandbox.message,Vl=n.sendRequestToFrame,Ol="ui|hide|request",Pl="ui|hide|response",Fl="ui|show|request",$l="ui|show|response";kl.on(kl.SERVICE_MSG_RECEIVED_EVENT,function(t){t.message.cmd===Ol?(h.hide(),kl.sendServiceMsg({cmd:Pl},t.source)):t.message.cmd===Fl&&(h.show(),kl.sendServiceMsg({cmd:$l},t.source))});var Ll={};Ll.uiRoot=h,Ll.cursorUI=ge,Ll.iframeCursorUI=_e,Ll.selectElement=i,Ll.modalBackground=k,Ll.ProgressPanel=Y,Ll.StatusBar=qt,Ll.IframeStatusBar=Jt,Ll.SelectorInspectorPanel=Ul,Ll.hide=function(t){return t?Vl({cmd:Ol},Pl,jl.top):(h.hide(),Dl.resolve())},Ll.show=function(t){return t?Vl({cmd:Fl},$l,jl.top):(h.show(),Dl.resolve())},Ll.showScreenshotMark=function(t){return Ce.show(t)},Ll.hideScreenshotMark=function(){return Ce.hide()};var zl=t.nativeMethods,Hl=t.EVENTS.evalIframeScript;zl.objectDefineProperty(jl,"%testCafeUI%",{configurable:!0,value:Ll}),t.on(Hl,function(t){return Wl(zl.contentWindowGetter.call(t.iframe))})}(jl["%hammerhead%"],jl["%testCafeCore%"],jl["%hammerhead%"].Promise)}(window);
@@ -39,4 +39,19 @@
39
39
  <path d="M11 8L20 15L11 22V8Z" fill="white"/>
40
40
  </svg>
41
41
  </g>
42
+ <g class="sprite" id="arrow-down">
43
+ <svg width="16" height="8" viewBox="0 0 16 8" fill="none" xmlns="http://www.w3.org/2000/svg">
44
+ <path d="M0 0h16L8 8 0 0z" fill="#667599"/>
45
+ </svg>
46
+ </g>
47
+ <g class="sprite" id="expand-button">
48
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
49
+ <path d="M6 8h8 L10 12Z" fill="#2D3F53"/>
50
+ </svg>
51
+ </g>
52
+ <g class="sprite" id="disabled-expand-button">
53
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
54
+ <path d="M6 8h8 L10 12Z" fill="#b4b9be"/>
55
+ </svg>
56
+ </g>
42
57
  </svg>