pleroma/priv/static/packs/public.js

2 lines
7 KiB
JavaScript
Raw Normal View History

2018-09-20 16:10:13 +00:00
(window.webpackJsonp=window.webpackJsonp||[]).push([[88],{447:function(e,t,n){var o,r,a;r=[],void 0===(a="function"==typeof(o=function(){var e=function(t,n){"use strict";var o=Object.create(e.prototype),r=0,a=0,i=0,c=0,l=[],s=!0,u=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame||function(e){setTimeout(e,1e3/60)},d=window.transformProp||function(){var e=document.createElement("div");if(null===e.style.transform){var t=["Webkit","Moz","ms"];for(var n in t)if(void 0!==e.style[t[n]+"Transform"])return t[n]+"Transform"}return"transform"}();o.options={speed:-2,center:!1,wrapper:null,round:!0,vertical:!0,horizontal:!1,callback:function(){}},n&&Object.keys(n).forEach(function(e){o.options[e]=n[e]}),t||(t=".rellax");var m="string"==typeof t?document.querySelectorAll(t):[t];if(!(m.length>0))throw new Error("The elements you're trying to select don't exist.");if(o.elems=m,o.options.wrapper&&!o.options.wrapper.nodeType){var p=document.querySelector(o.options.wrapper);if(!p)throw new Error("The wrapper you're trying to use don't exist.");o.options.wrapper=p}var f=function(){for(var e=0;e<l.length;e++)o.elems[e].style.cssText=l[e].style;l=[],a=window.innerHeight,c=window.innerWidth,w(),function(){for(var e=0;e<o.elems.length;e++){var t=g(o.elems[e]);l.push(t)}}(),s&&(window.addEventListener("resize",f),s=!1),v()},g=function(e){var t=e.getAttribute("data-rellax-percentage"),n=e.getAttribute("data-rellax-speed"),r=e.getAttribute("data-rellax-zindex")||0,i=o.options.wrapper?o.options.wrapper.scrollTop:window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop,l=o.options.vertical&&(t||o.options.center)?i:0,s=o.options.horizontal&&(t||o.options.center)?window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft:0,u=l+e.getBoundingClientRect().top,d=e.clientHeight||e.offsetHeight||e.scrollHeight,m=s+e.getBoundingClientRect().left,p=e.clientWidth||e.offsetWidth||e.scrollWidth,f=t||(l-u+a)/(d+a),g=t||(s-m+c)/(p+c);o.options.center&&(g=.5,f=.5);var w=n||o.options.speed,y=h(g,f,w),v=e.style.cssText,b="";if(v.indexOf("transform")>=0){var x=v.indexOf("transform"),T=v.slice(x),q=T.indexOf(";");b=q?" "+T.slice(11,q).replace(/\s/g,""):" "+T.slice(11).replace(/\s/g,"")}return{baseX:y.x,baseY:y.y,top:u,left:m,height:d,width:p,speed:w,style:v,transform:b,zindex:r}},w=function(){var e=r,t=i;return r=o.options.wrapper?o.options.wrapper.scrollTop:(document.documentElement||document.body.parentNode||document.body).scrollTop||window.pageYOffset,i=o.options.wrapper?o.options.wrapper.scrollLeft:(document.documentElement||document.body.parentNode||document.body).scrollLeft||window.pageXOffset,!(e==r||!o.options.vertical)||!(t==i||!o.options.horizontal)},h=function(e,t,n){var r={},a=n*(100*(1-e)),i=n*(100*(1-t));return r.x=o.options.round?Math.round(a):Math.round(100*a)/100,r.y=o.options.round?Math.round(i):Math.round(100*i)/100,r},y=function(){w()&&!1===s&&v(),u(y)},v=function(){for(var e,t=0;t<o.elems.length;t++){var n=(r-l[t].top+a)/(l[t].height+a),s=(i-l[t].left+c)/(l[t].width+c),u=(e=h(s,n,l[t].speed)).y-l[t].baseY,m=e.x-l[t].baseX,p=l[t].zindex,f="translate3d("+(o.options.horizontal?m:"0")+"px,"+(o.options.vertical?u:"0")+"px,"+p+"px) "+l[t].transform;o.elems[t].style[d]=f}o.options.callback(e)};return o.destroy=function(){for(var e=0;e<o.elems.length;e++)o.elems[e].style.cssText=l[e].style;s||(window.removeEventListener("resize",f),s=!0)},f(),y(),o.refresh=f,o};return e})?o.apply(t,r):o)||(e.exports=a)},449:function(e,t,n){"use strict";n.r(t);var o=n(0),r=n.n(o),a=n(67),i=n(80),c=n(66);Object(c.a)(),window.addEventListener("message",function(e){var t=e.data||{};window.parent&&"setHeight"===t.type&&Object(i.default)(function(){window.parent.postMessage({type:"setHeight",id:t.id,height:document.getElementsByTagName("html")[0].scrollHeight},"*")})}),Object(a.a)().then(function(){var e=n(103).length,t=n(52).default,o=n(81).timeAgoString,a=n(58).delegate,c=n(47).default,l=(0,n(8).getLocale)().messages,s=(
//# sourceMappingURL=public.js.map