@assaabloy/amarr-wc-scroll-top 2.0.2 → 2.0.3
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/package.json +2 -2
- package/scroll-top.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@assaabloy/amarr-wc-scroll-top",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.3",
|
|
4
4
|
"description": "Web component - Scroll-top",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "scroll-top.js",
|
|
@@ -11,5 +11,5 @@
|
|
|
11
11
|
},
|
|
12
12
|
"author": "Nagarro",
|
|
13
13
|
"license": "MIT",
|
|
14
|
-
"gitHead": "
|
|
14
|
+
"gitHead": "eaa503924798968e98b8f6766bedbb7ec871382c"
|
|
15
15
|
}
|
package/scroll-top.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(t){function e(e){for(var r,i,c=e[0],u=e[1],s=e[2],f=0,p=[];f<c.length;f++)i=c[f],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(r in u)Object.prototype.hasOwnProperty.call(u,r)&&(t[r]=u[r]);for(l&&l(e);p.length;)p.shift()();return a.push.apply(a,s||[]),n()}function n(){for(var t,e=0;e<a.length;e++){for(var n=a[e],r=!0,c=1;c<n.length;c++){var u=n[c];0!==o[u]&&(r=!1)}r&&(a.splice(e--,1),t=i(i.s=n[0]))}return t}var r={},o={68:0},a=[];function i(e){if(r[e])return r[e].exports;var n=r[e]={i:e,l:!1,exports:{}};return t[e].call(n.exports,n,n.exports,i),n.l=!0,n.exports}i.m=t,i.c=r,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)i.d(n,r,function(e){return t[e]}.bind(null,r));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="/";var c=this["webpackJsonpamarr-frontend-components"]=this["webpackJsonpamarr-frontend-components"]||[],u=c.push.bind(c);c.push=e,c=c.slice();for(var s=0;s<c.length;s++)e(c[s]);var l=u;a.push([
|
|
1
|
+
!function(t){function e(e){for(var r,i,c=e[0],u=e[1],s=e[2],f=0,p=[];f<c.length;f++)i=c[f],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&p.push(o[i][0]),o[i]=0;for(r in u)Object.prototype.hasOwnProperty.call(u,r)&&(t[r]=u[r]);for(l&&l(e);p.length;)p.shift()();return a.push.apply(a,s||[]),n()}function n(){for(var t,e=0;e<a.length;e++){for(var n=a[e],r=!0,c=1;c<n.length;c++){var u=n[c];0!==o[u]&&(r=!1)}r&&(a.splice(e--,1),t=i(i.s=n[0]))}return t}var r={},o={68:0},a=[];function i(e){if(r[e])return r[e].exports;var n=r[e]={i:e,l:!1,exports:{}};return t[e].call(n.exports,n,n.exports,i),n.l=!0,n.exports}i.m=t,i.c=r,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)i.d(n,r,function(e){return t[e]}.bind(null,r));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="/";var c=this["webpackJsonpamarr-frontend-components"]=this["webpackJsonpamarr-frontend-components"]||[],u=c.push.bind(c);c.push=e,c=c.slice();for(var s=0;s<c.length;s++)e(c[s]);var l=u;a.push([520,0]),n()}({0:function(t,e){t.exports=React},114:function(t,e,n){"use strict";var r=n(2),o=n(15),a=n(0),i=n.n(a),c=n(4).default.section.withConfig({displayName:"styles__Content",componentId:"sc-9ib1mp-0"})([".bottom-to-top{position:fixed;width:2.7rem;bottom:2.7rem;right:1rem;cursor:pointer;z-index:999;}"]),u=function(t){Object(o.a)(t);var e=Object(a.useState)(0),n=Object(r.a)(e,2),u=n[0],s=n[1],l=Object(a.useState)(!1),f=Object(r.a)(l,2),p=f[0],d=f[1];function m(){s(window.pageYOffset)}return Object(a.useEffect)((function(){!function(){window.addEventListener("scroll",m);var t=document.body.scrollHeight/5.2;d(u>t)}()}),[u]),i.a.createElement(c,null,p&&i.a.createElement("img",{className:"bottom-to-top hide-print-media",src:"/etc.clientlibs/amarr/clientlibs/themes/amarr/resources/images/ic-bottom-up-arrow.svg",alt:"Edit Icon",onClick:function(){window.scrollTo({top:0,behavior:"smooth"})}}))};u.defaultProps={theme:""};e.a=u},18:function(t,e){t.exports=ReactDOM},431:function(t,e,n){"use strict";n.r(e);var r=n(13),o=n(114);e.default=r.a.create({component:o.a,configuration:{tagname:"amarr-scroll-top",useShadow:!1},plugins:[]})}});
|