@applitools/snippets 2.2.3 → 2.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -106,6 +106,10 @@ exports.isEqualElements=function(arg){
106
106
  var s=function(){"use strict";return function(r){var n=void 0===r?[]:r;return n[0]===n[1]}}();
107
107
  return s(arg)
108
108
  }
109
+ exports.lazyLoad=function(arg){
110
+ var s=function(){"use strict";var o=function(o){var t=(void 0===o?[]:o)[0];return t?{x:t.scrollLeft,y:t.scrollTop}:{x:window.scrollX||window.pageXOffset,y:window.scrollY||window.pageYOffset}};var t=function(o){var t=void 0===o?[]:o,r=t[0],e=t[1],l=Object.keys(e).sort(),n=l.reduce((function(o,t){return o[t]={value:r.style.getPropertyValue(t),important:Boolean(r.style.getPropertyPriority(t))},o}),{});return l.forEach((function(o){r.style.setProperty(o,"string"!=typeof e[o]&&e[o]?e[o].value:e[o],e[o]&&e[o].important?"important":"")})),n};var r=function(o){var r=void 0===o?[]:o,e=r[0],l=r[1];e=e||document.documentElement;var n=t([e,{"scroll-behavior":{value:"auto",important:!0}}]);return e.scrollTo?e.scrollTo(l.x,l.y):(e.scrollLeft=l.x,e.scrollTop=l.y),t([e,n]),{x:e.scrollLeft,y:e.scrollTop}},e="__EYES__APPLITOOLS__";return window[e]=window[e]||{},function(t){var l=(void 0===t?[]:t)[0],n=(l=void 0===l?{}:l).scrollLength,i=l.waitingTime,a=l.maxAmountToScroll;try{if(window[e].lazyLoadResult){var s=window[e].lazyLoadResult;return"WIP"!==s.status&&delete window[e].lazyLoadResult,JSON.stringify(s)}window[e].lazyLoadResult={status:"WIP"};var u=o(),c=[];c.push({maxAmountToScroll:a,scrollLength:n,waitingTime:i,startingScrollPositionX:u.x,startingScrollPositionY:u.y});var d=Date.now();return function o(t){var l=void 0===t?{}:t,s=l.doneScrolling,y=l.previousScrollResult,w=void 0===y?{}:y;setTimeout((function(){try{if(s){var t=r([void 0,u]),l=t.x,i=t.y;return c.push({x:l,y:i,msSinceStart:Date.now()-d}),void(window[e].lazyLoadResult={status:"SUCCESS",value:c})}var y=r([void 0,{x:u.x,y:w.y+n}]),v=y.x,f=y.y;c.push({x:v,y:f,msSinceStart:Date.now()-d}),o({doneScrolling:f===w.y||f===a,previousScrollResult:{x:v,y:f}})}catch(o){window[e].lazyLoadResult={status:"ERROR",error:o}}}),i)}(),JSON.stringify(window[e].lazyLoadResult)}catch(o){return window[e].lazyLoadResult={status:"ERROR",error:o},JSON.stringify(window[e].lazyLoadResult)}}}();
111
+ return s(arg)
112
+ }
109
113
  exports.scrollTo=function(arg){
110
114
  var s=function(){"use strict";var t=function(t){var r=void 0===t?[]:t,o=r[0],e=r[1],l=Object.keys(e).sort(),n=l.reduce((function(t,r){return t[r]={value:o.style.getPropertyValue(r),important:Boolean(o.style.getPropertyPriority(r))},t}),{});return l.forEach((function(t){o.style.setProperty(t,"string"!=typeof e[t]&&e[t]?e[t].value:e[t],e[t]&&e[t].important?"important":"")})),n};return function(r){var o=void 0===r?[]:r,e=o[0],l=o[1];e=e||document.documentElement;var n=t([e,{"scroll-behavior":{value:"auto",important:!0}}]);return e.scrollTo?e.scrollTo(l.x,l.y):(e.scrollLeft=l.x,e.scrollTop=l.y),t([e,n]),{x:e.scrollLeft,y:e.scrollTop}}}();
111
115
  return s(arg)
package/package.json CHANGED
@@ -1,15 +1,23 @@
1
1
  {
2
2
  "name": "@applitools/snippets",
3
- "version": "2.2.3",
3
+ "version": "2.4.2",
4
+ "repository": {
5
+ "type": "git",
6
+ "url": "https://github.com/applitools/eyes.sdk.javascript1.git",
7
+ "directory": "packages/snippets"
8
+ },
4
9
  "license": "SEE LICENSE IN LICENSE",
10
+ "aliases": [
11
+ "snippets"
12
+ ],
5
13
  "main": "./dist/index.js",
6
14
  "files": [
7
15
  "dist"
8
16
  ],
9
17
  "scripts": {
10
18
  "lint": "eslint '**/*.js'",
11
- "build": "node ./rollup/cli bundle --format json --format snippet",
12
- "build:watch": "node ./rollup/cli watch --format json --format snippet",
19
+ "build": "node ./rollup/cli bundle --format snippet",
20
+ "build:watch": "node ./rollup/cli watch --format snippet",
13
21
  "test": "mocha --no-timeouts --require test/util/hook.js ./test/*.spec.js",
14
22
  "test:chrome": "mocha --no-timeouts --require test/util/hook.js --grep chrome ./test/*.spec.js",
15
23
  "test:ie": "mocha --no-timeouts --require test/util/hook.js --grep 'internet explorer' ./test/*.spec.js",
@@ -19,19 +27,9 @@
19
27
  "version": "bongo version",
20
28
  "postversion": "bongo postversion --skip-release-notification"
21
29
  },
22
- "husky": {
23
- "hooks": {
24
- "pre-push": "yarn bongo lint"
25
- }
26
- },
27
- "repository": {
28
- "type": "git",
29
- "url": "https://github.com/applitools/eyes.sdk.javascript1.git",
30
- "directory": "packages/snippets"
31
- },
32
30
  "dependencies": {},
33
31
  "devDependencies": {
34
- "@applitools/bongo": "^2.0.3",
32
+ "@applitools/bongo": "^2.1.5",
35
33
  "@babel/core": "^7.11.6",
36
34
  "@babel/preset-env": "^7.11.5",
37
35
  "@rollup/plugin-babel": "^5.2.1",
@@ -48,13 +46,18 @@
48
46
  "prettier": "1.19.0",
49
47
  "rollup": "^2.26.11",
50
48
  "rollup-plugin-terser": "^7.0.2",
51
- "webdriverio": "^6.1.24",
49
+ "webdriverio": "^7.20.2",
52
50
  "yargs": "^16.0.3"
53
51
  },
54
- "engines": {
55
- "node": ">=8.9.0"
56
- },
57
52
  "resolutions": {
58
53
  "chromedriver": "^98.0.0"
54
+ },
55
+ "engines": {
56
+ "node": ">=12.13.0"
57
+ },
58
+ "husky": {
59
+ "hooks": {
60
+ "pre-push": "yarn bongo lint"
61
+ }
59
62
  }
60
63
  }
@@ -1,33 +0,0 @@
1
- {
2
- "addElementIds": "function(arg){var s=function(){\"use strict\";return function(t){var o=t[0],e=t[1];return o.map((function(t,o){var r=[t];if(t.getRootNode)for(var a=t.getRootNode();a!==document;a=a.host.getRootNode())r.push(a.host);var n=e[o];return r.map((function(t){var o=t.getAttribute(\"data-applitools-selector\"),e=o?o+\" \"+n:n;return t.setAttribute(\"data-applitools-selector\",e),'[data-applitools-selector~=\"'+n+'\"]'}))}))}}();\nreturn s(arg)}",
3
- "addPageMarker": "function(arg){var s=function(){\"use strict\";var t=function(t){var e=void 0===t?[]:t,r=e[0],o=e[1],n=Object.keys(o).sort(),i=n.reduce((function(t,e){return t[e]={value:r.style.getPropertyValue(e),important:Boolean(r.style.getPropertyPriority(e))},t}),{});return n.forEach((function(t){r.style.setProperty(t,\"string\"!=typeof o[t]&&o[t]?o[t].value:o[t],o[t]&&o[t].important?\"important\":\"\")})),i};return function(e){var r=e[0],o=r.mask,n=r.size,i=void 0===n?1:n,a={1:\"rgb(0, 0, 0)\",0:\"rgb(255, 255, 255)\"},s=i,p=document.createElement(\"div\");p.setAttribute(\"data-applitools-marker\",\"\"),p.style.setProperty(\"position\",\"fixed\",\"important\"),p.style.setProperty(\"top\",\"0\",\"important\"),p.style.setProperty(\"left\",\"0\",\"important\"),p.style.setProperty(\"box-sizing\",\"content-box\",\"important\"),p.style.setProperty(\"padding\",s+\"px\",\"important\"),p.style.setProperty(\"background\",\"rgb(128, 128, 128)\",\"important\"),p.style.setProperty(\"z-index\",\"2147483647\",\"important\");for(var l,y=0;y<o.length;y+=l){for(l=1;o[y]===o[y+l];)++l;var m=o[y],d=document.createElement(\"div\");d.style.setProperty(\"display\",\"block\",\"important\"),d.style.setProperty(\"float\",\"left\",\"important\"),d.style.setProperty(\"width\",l*i+\"px\",\"important\"),d.style.setProperty(\"height\",i+\"px\",\"important\"),d.style.setProperty(\"background\",a[m],\"important\"),p.appendChild(d)}var u={value:\"none\",important:!0},c=t([document.documentElement,{transform:u,\"-webkit-transform\":u}]),f=t([document.body,{transform:u,\"-webkit-transform\":u}]);return document.documentElement.setAttribute(\"data-applitools-original-transforms\",JSON.stringify(c)),document.body.setAttribute(\"data-applitools-original-transforms\",JSON.stringify(f)),document.body.appendChild(p),{mask:o,size:i,offset:s}}}();\nreturn s(arg)}",
4
- "blurElement": "function(arg){var s=function(){\"use strict\";return function(t){var n=(void 0===t?[]:t)[0]||document.activeElement;return n&&n.blur(),n}}();\nreturn s(arg)}",
5
- "cleanupElementIds": "function(arg){var s=function(){\"use strict\";return function(t){t[0].forEach((function(t){if(t.removeAttribute(\"data-applitools-selector\"),t.getRootNode)for(var o=t.getRootNode();o!==document;o=o.host.getRootNode())o.host.removeAttribute(\"data-applitools-selector\")}))}}();\nreturn s(arg)}",
6
- "cleanupPageMarker": "function(arg){var s=function(){\"use strict\";var t=function(t){var e=void 0===t?[]:t,r=e[0],o=e[1],n=Object.keys(o).sort(),a=n.reduce((function(t,e){return t[e]={value:r.style.getPropertyValue(e),important:Boolean(r.style.getPropertyPriority(e))},t}),{});return n.forEach((function(t){r.style.setProperty(t,\"string\"!=typeof o[t]&&o[t]?o[t].value:o[t],o[t]&&o[t].important?\"important\":\"\")})),a};return function(){var e=document.querySelector(\"[data-applitools-marker]\");e&&document.body.removeChild(e);var r=document.documentElement.getAttribute(\"data-applitools-original-transforms\"),o=document.body.getAttribute(\"data-applitools-original-transforms\");r&&t([document.documentElement,JSON.parse(r)]),o&&t([document.body,JSON.parse(o)])}}();\nreturn s(arg)}",
7
- "focusElement": "function(arg){var s=function(){\"use strict\";return function(n){var r=(void 0===n?[]:n)[0];r&&r.focus()}}();\nreturn s(arg)}",
8
- "getChildFramesInfo": "function(arg){var s=function(){\"use strict\";return function(){var r=document.querySelectorAll(\"frame, iframe\");return Array.prototype.map.call(r,(function(r){return[r,!r.contentDocument,r.src]}))}}();\nreturn s(arg)}",
9
- "getContextInfo": "function(arg){var s=function(){\"use strict\";var t=function(t){var n=(void 0===t?[]:t)[0],e=\"\",r=n.ownerDocument;if(!r)return e;for(var o=n;o!==r;){var a=Array.prototype.filter.call(o.parentNode.childNodes,(function(t){return t.tagName===o.tagName})).indexOf(o);e=\"/\"+o.tagName+\"[\"+(a+1)+\"]\"+e,o=o.parentNode}return e};return function(){var n,e,r;try{n=window.top.document===window.document||\"root-context\"===window.document[\"applitools-marker\"]}catch(t){n=!1}try{e=!window.parent.document===window.document}catch(t){e=!0}if(!e)try{r=t([window.frameElement])}catch(t){r=null}return[document.documentElement,r,n,e]}}();\nreturn s(arg)}",
10
- "getDocumentScrollingElement": "function(arg){var s=function(){\"use strict\";return function(){var t=\"HTML\",e=document.scrollingElement;return e&&(t=e.tagName),t.toLowerCase()}}();\nreturn s(arg)}",
11
- "getDocumentSize": "function(arg){var s=function(){\"use strict\";return function(){var t=document.documentElement.scrollWidth,e=document.documentElement.scrollHeight,n=document.documentElement.clientHeight,c=document.body.scrollWidth,o=document.body.scrollHeight,d=document.body.clientHeight;return{width:Math.max(t,c),height:Math.max(n,e,d,o)}}}();\nreturn s(arg)}",
12
- "getElementComputedStyleProperties": "function(arg){var s=function(){\"use strict\";return function(t){var r=void 0===t?[]:t,e=r[0],n=r[1],u=void 0===n?[]:n,o=window.getComputedStyle(e);return o?u.map((function(t){return o.getPropertyValue(t)})):[]}}();\nreturn s(arg)}",
13
- "getElementContentSize": "function(arg){var s=function(){\"use strict\";var t=function(t){var e=void 0===t?[]:t,r=e[0],o=e[1],n=Object.keys(o).sort(),a=n.reduce((function(t,e){return t[e]={value:r.style.getPropertyValue(e),important:Boolean(r.style.getPropertyPriority(e))},t}),{});return n.forEach((function(t){r.style.setProperty(t,\"string\"!=typeof o[t]&&o[t]?o[t].value:o[t],o[t]&&o[t].important?\"important\":\"\")})),a};return function(e){var r,o,n,a=(void 0===e?[]:e)[0];a!==document.documentElement&&a.tagName.toLowerCase()!==(o=\"HTML\",(n=document.scrollingElement)&&(o=n.tagName),o.toLowerCase())||(r=t([a,{transform:\"none\"}]));var i={width:a.scrollWidth,height:a.scrollHeight};return r&&t([a,r]),i}}();\nreturn s(arg)}",
14
- "getElementFixedAncestor": "function(arg){var s=function(){\"use strict\";return function(t){for(var e=(void 0===t?[]:t)[0];e.offsetParent&&e.offsetParent!==document.body&&e.offsetParent!==document.documentElement;)e=e.offsetParent;return\"fixed\"===window.getComputedStyle(e).getPropertyValue(\"position\")?e:null}}();\nreturn s(arg)}",
15
- "getElementInnerOffset": "function(arg){var s=function(){\"use strict\";var r=function(r){var t=(void 0===r?[]:r)[0];return t?{x:t.scrollLeft,y:t.scrollTop}:{x:window.scrollX||window.pageXOffset,y:window.scrollY||window.pageYOffset}};var t=function(r){var t=void 0===r?[]:r,e=t[0],o=t[1];return(void 0===o?[]:o).reduce((function(r,t){return r[t]={value:e.style.getPropertyValue(t),important:Boolean(e.style.getPropertyPriority(t))},r}),{})};var e=function(r){var e=(void 0===r?[]:r)[0],o=void 0===e?document.documentElement:e,n=t([o,[\"transform\",\"-webkit-transform\"]]),i=Object.keys(n).reduce((function(r,t){var e=n[t].value;if(e){var o=e.match(/^translate\\s*\\(\\s*(\\-?[\\d, \\.]+)px\\s*(,\\s*(-?[\\d, \\.]+)px)?\\s*\\)/);if(o){var i=o[1],a=void 0!==o[3]?o[3]:0;r.push({x:Math.round(-parseFloat(i)),y:Math.round(-parseFloat(a))})}else r.push({x:0,y:0})}return r}),[]);if(!i.every((function(r){return i[0].x===r.x||i[0].y===r.y})))throw new Error(\"Got different css positions!\");return i[0]||{x:0,y:0}};return function(t){var o=(void 0===t?[]:t)[0],n=r([o]),i=e([o]);return{x:n.x+i.x,y:n.y+i.y}}}();\nreturn s(arg)}",
16
- "getElementProperties": "function(arg){var s=function(){\"use strict\";return function(r){var n=void 0===r?[]:r,t=n[0],u=n[1];return(void 0===u?[]:u).reduce((function(r,n){return r[n]=t[n],r}),{})}}();\nreturn s(arg)}",
17
- "getElementRect": "function(arg){var s=function(){\"use strict\";var t=function(t){for(var e=(void 0===t?[]:t)[0];e.offsetParent&&e.offsetParent!==document.body&&e.offsetParent!==document.documentElement;)e=e.offsetParent;return\"fixed\"===window.getComputedStyle(e).getPropertyValue(\"position\")?e:null};var e=function(t){var e=(void 0===t?[]:t)[0];return e?{x:e.scrollLeft,y:e.scrollTop}:{x:window.scrollX||window.pageXOffset,y:window.scrollY||window.pageYOffset}};var r=function(t){var e=void 0===t?[]:t,r=e[0],o=e[1];return(void 0===o?[]:o).reduce((function(t,e){return t[e]={value:r.style.getPropertyValue(e),important:Boolean(r.style.getPropertyPriority(e))},t}),{})};var o=function(t){var e=(void 0===t?[]:t)[0],o=void 0===e?document.documentElement:e,n=r([o,[\"transform\",\"-webkit-transform\"]]),i=Object.keys(n).reduce((function(t,e){var r=n[e].value;if(r){var o=r.match(/^translate\\s*\\(\\s*(\\-?[\\d, \\.]+)px\\s*(,\\s*(-?[\\d, \\.]+)px)?\\s*\\)/);if(o){var i=o[1],a=void 0!==o[3]?o[3]:0;t.push({x:Math.round(-parseFloat(i)),y:Math.round(-parseFloat(a))})}else t.push({x:0,y:0})}return t}),[]);if(!i.every((function(t){return i[0].x===t.x||i[0].y===t.y})))throw new Error(\"Got different css positions!\");return i[0]||{x:0,y:0}};var n=function(t){var r=(void 0===t?[]:t)[0],n=e([r]),i=o([r]);return{x:n.x+i.x,y:n.y+i.y}};return function(e){var r,o,i=void 0===e?[]:e,a=i[0],d=i[1],u=void 0!==d&&d;if(a===document.documentElement||a.tagName.toLowerCase()===(r=\"HTML\",(o=document.scrollingElement)&&(r=o.tagName),r.toLowerCase()))return{x:0,y:0,width:a.clientWidth,height:a.clientHeight};var s=a.getBoundingClientRect(),l={x:s.left,y:s.top,width:s.width,height:s.height};if(u){var f=window.getComputedStyle(a);l.x+=parseInt(f.getPropertyValue(\"border-left-width\")),l.y+=parseInt(f.getPropertyValue(\"border-top-width\")),l.width=a.clientWidth,l.height=a.clientHeight}var c=t([a]);if(c){if(c!==a){var v=n([c]);l.x+=v.x,l.y+=v.y}}else{var y=n();l.x+=y.x,l.y+=y.y}return l}}();\nreturn s(arg)}",
18
- "getElementScrollOffset": "function(arg){var s=function(){\"use strict\";return function(o){var r=(void 0===o?[]:o)[0];return r?{x:r.scrollLeft,y:r.scrollTop}:{x:window.scrollX||window.pageXOffset,y:window.scrollY||window.pageYOffset}}}();\nreturn s(arg)}",
19
- "getElementStyleProperties": "function(arg){var s=function(){\"use strict\";return function(r){var t=void 0===r?[]:r,e=t[0],n=t[1];return(void 0===n?[]:n).reduce((function(r,t){return r[t]={value:e.style.getPropertyValue(t),important:Boolean(e.style.getPropertyPriority(t))},r}),{})}}();\nreturn s(arg)}",
20
- "getElementTranslateOffset": "function(arg){var s=function(){\"use strict\";var r=function(r){var t=void 0===r?[]:r,e=t[0],n=t[1];return(void 0===n?[]:n).reduce((function(r,t){return r[t]={value:e.style.getPropertyValue(t),important:Boolean(e.style.getPropertyPriority(t))},r}),{})};return function(t){var e=(void 0===t?[]:t)[0],n=void 0===e?document.documentElement:e,o=r([n,[\"transform\",\"-webkit-transform\"]]),u=Object.keys(o).reduce((function(r,t){var e=o[t].value;if(e){var n=e.match(/^translate\\s*\\(\\s*(\\-?[\\d, \\.]+)px\\s*(,\\s*(-?[\\d, \\.]+)px)?\\s*\\)/);if(n){var u=n[1],a=void 0!==n[3]?n[3]:0;r.push({x:Math.round(-parseFloat(u)),y:Math.round(-parseFloat(a))})}else r.push({x:0,y:0})}return r}),[]);if(!u.every((function(r){return u[0].x===r.x||u[0].y===r.y})))throw new Error(\"Got different css positions!\");return u[0]||{x:0,y:0}}}();\nreturn s(arg)}",
21
- "getElementXpath": "function(arg){var s=function(){\"use strict\";return function(r){var e=(void 0===r?[]:r)[0],t=\"\",n=e.ownerDocument;if(!n)return t;for(var a=e;a!==n;){var o=Array.prototype.filter.call(a.parentNode.childNodes,(function(r){return r.tagName===a.tagName})).indexOf(a);t=\"/\"+a.tagName+\"[\"+(o+1)+\"]\"+t,a=a.parentNode}return t}}();\nreturn s(arg)}",
22
- "getPixelRatio": "function(arg){var s=function(){\"use strict\";return function(){return window.devicePixelRatio}}();\nreturn s(arg)}",
23
- "getShadowRoot": "function(arg){var s=function(){\"use strict\";return function(t){return(void 0===t?[]:t)[0].shadowRoot}}();\nreturn s(arg)}",
24
- "getUserAgent": "function(arg){var s=function(){\"use strict\";return function(){return window.navigator.userAgent}}();\nreturn s(arg)}",
25
- "getViewportScale": "function(arg){var s=function(){\"use strict\";return function(){return window.visualViewport&&window.visualViewport.scale}}();\nreturn s(arg)}",
26
- "getViewportSize": "function(arg){var s=function(){\"use strict\";return function(){var e=0,t=0;return window.innerHeight?t=window.innerHeight:document.documentElement&&document.documentElement.clientHeight?t=document.documentElement.clientHeight:document.body&&document.body.clientHeight&&(t=document.body.clientHeight),window.innerWidth?e=window.innerWidth:document.documentElement&&document.documentElement.clientWidth?e=document.documentElement.clientWidth:document.body&&document.body.clientWidth&&(e=document.body.clientWidth),{width:e,height:t}}}();\nreturn s(arg)}",
27
- "isElementScrollable": "function(arg){var s=function(){\"use strict\";var t=function(t){var o=void 0===t?[]:t,r=o[0],e=o[1],i=void 0===e?[]:e,n=window.getComputedStyle(r);return n?i.map((function(t){return n.getPropertyValue(t)})):[]};return function(o){var r=(void 0===o?[]:o)[0],e=t([r,[\"overflow-x\",\"overflow-y\",\"overflow\"]]);return(\"scroll\"===e[0]||\"auto\"===e[0]||\"hidden\"===e[2])&&r.scrollWidth>r.clientWidth||(\"scroll\"===e[1]||\"auto\"===e[1]||\"hidden\"===e[2])&&r.scrollHeight>r.clientHeight}}();\nreturn s(arg)}",
28
- "isEqualElements": "function(arg){var s=function(){\"use strict\";return function(r){var n=void 0===r?[]:r;return n[0]===n[1]}}();\nreturn s(arg)}",
29
- "scrollTo": "function(arg){var s=function(){\"use strict\";var t=function(t){var r=void 0===t?[]:t,o=r[0],e=r[1],l=Object.keys(e).sort(),n=l.reduce((function(t,r){return t[r]={value:o.style.getPropertyValue(r),important:Boolean(o.style.getPropertyPriority(r))},t}),{});return l.forEach((function(t){o.style.setProperty(t,\"string\"!=typeof e[t]&&e[t]?e[t].value:e[t],e[t]&&e[t].important?\"important\":\"\")})),n};return function(r){var o=void 0===r?[]:r,e=o[0],l=o[1];e=e||document.documentElement;var n=t([e,{\"scroll-behavior\":{value:\"auto\",important:!0}}]);return e.scrollTo?e.scrollTo(l.x,l.y):(e.scrollLeft=l.x,e.scrollTop=l.y),t([e,n]),{x:e.scrollLeft,y:e.scrollTop}}}();\nreturn s(arg)}",
30
- "setElementAttributes": "function(arg){var s=function(){\"use strict\";return function(t){var e=void 0===t?[]:t,r=e[0],u=e[1];return Object.keys(u).reduce((function(t,e){return t[e]=r.getAttribute(e),r.setAttribute(e,u[e]),t}),{})}}();\nreturn s(arg)}",
31
- "setElementStyleProperties": "function(arg){var s=function(){\"use strict\";return function(t){var r=void 0===t?[]:t,e=r[0],o=r[1],n=Object.keys(o).sort(),i=n.reduce((function(t,r){return t[r]={value:e.style.getPropertyValue(r),important:Boolean(e.style.getPropertyPriority(r))},t}),{});return n.forEach((function(t){e.style.setProperty(t,\"string\"!=typeof o[t]&&o[t]?o[t].value:o[t],o[t]&&o[t].important?\"important\":\"\")})),i}}();\nreturn s(arg)}",
32
- "translateTo": "function(arg){var s=function(){\"use strict\";var t=function(t){var r=void 0===t?[]:t,e=r[0],n=r[1],o=Object.keys(n).sort(),a=o.reduce((function(t,r){return t[r]={value:e.style.getPropertyValue(r),important:Boolean(e.style.getPropertyPriority(r))},t}),{});return o.forEach((function(t){e.style.setProperty(t,\"string\"!=typeof n[t]&&n[t]?n[t].value:n[t],n[t]&&n[t].important?\"important\":\"\")})),a};return function(r){var e=void 0===r?[]:r,n=e[0],o=e[1];n=n||document.documentElement;var a={value:\"translate(\"+-o.x+\"px, \"+-o.y+\"px)\",important:!0};return t([n,{transform:a,\"-webkit-transform\":a}]),o}}();\nreturn s(arg)}"
33
- }