PageSourceSearch

https://www.messe-offenbach.de/wp-content/cache/autoptimize/js/aut…_single_818740c2785659d2e489b2fd8bc4081e.js

js messe-offenbach.de collected 2026-10-05 00:41:58 UTC 9,620 bytes, 89 lines download raw bytes

1(function($)
2{"use strict";$.avia_utilities=$.avia_utilities||{};$(function()
3{if($.fn.avia_parallax)
4{$('.av-parallax,.av-parallax-object').avia_parallax();}});var AviaObjectParallaxElement=function(options,element)
5{if(!(this.transform||this.transform3d))
6{return;}
7this.options=$.extend({},options);this.win=$(window);this.body=$('body');this.isMobile=$.avia_utilities.isMobile,this.winHeight=this.win.height();this.winWidth=this.win.width();this.el=$(element).addClass('active-parallax');this.objectType=this.el.hasClass('av-parallax-object')?'object':'background-image';this.elInner=this.el;this.elBackgroundParent=this.el.parent();this.elParallax=this.el.data('parallax')||{};this.direction='';this.speed=0.5;this.elProperty={};this.ticking=false,this.isTransformed=false;if($.avia_utilities.supported.transition===undefined)
8{$.avia_utilities.supported.transition=$.avia_utilities.supports('transition');}
9this._init(options);};AviaObjectParallaxElement.prototype={mediaQueries:{'av-mini-':'(max-width: 479px)','av-small-':'(min-width: 480px) and (max-width: 767px)','av-medium-':'(min-width: 768px) and (max-width: 989px)','av-desktop-':'(min-width: 990px)'},transform:document.documentElement.className.indexOf('avia_transform')!==-1,transform3d:document.documentElement.className.indexOf('avia_transform3d')!==-1,mobileNoAnimation:$('body').hasClass('avia-mobile-no-animations'),defaultSpeed:0.5,defaultDirections:['bottom_top','left_right','right_left','no_parallax'],transformCSSProps:['transform','-webkit-transform','-moz-transform','-ms-transform','-o-transform'],matrixDef:[1,0,0,1,0,0],matrix3dDef:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],_init:function()
10{var _self=this;if(typeof this.el.data('parallax-selector')!='undefined'&&this.el.data('parallax-selector')!=='')
11{this.elInner=this.el.find(this.el.data('parallax-selector'));if(this.elInner.length==0)
12{this.elInner=this.el;}}
13if('background-image'==this.objectType)
14{if(this.isMobile&&this.mobileNoAnimation)
15{return;}
16this.elParallax.parallax='bottom_top';this.elParallax.parallax_speed=parseFloat(this.el.data('avia-parallax-ratio'))||0.5;}
17setTimeout(function()
18{_self._fetchProperties();},30);this.win.on('debouncedresize av-height-change',_self._fetchProperties.bind(_self));this.body.on('av_resize_finished',_self._fetchProperties.bind(_self));setTimeout(function()
19{_self.win.on('scroll',_self._onScroll.bind(_self));},100);},_setParallaxProps:function()
20{if('background-image'==this.objectType)
21{this.direction=this.elParallax.parallax;this.speed=this.elParallax.parallax_speed;return;}
22var all_direction=this.elParallax.parallax||'',all_speed=this.elParallax.parallax_speed||'',resp_direction='',resp_speed='',media='all';if(this.defaultDirections.indexOf(all_direction)<0)
23{all_direction='no_parallax';}
24if(typeof window.matchMedia=='function')
25{$.each(this.mediaQueries,function(key,query)
26{var mql=window.matchMedia(query);if(mql.matches)
27{media=key;return false;}});}
28if('all'==media)
29{this.direction=all_direction;this.speed=''==all_speed?this.defaultSpeed:parseFloat(all_speed)/100.0;return;}
30resp_direction=this.elParallax[media+'parallax']||'';resp_speed=this.elParallax[media+'parallax_speed']||'';if('inherit'==resp_direction)
31{resp_direction=all_direction;resp_speed=all_speed;}
32if(this.defaultDirections.indexOf(resp_direction)<0)
33{resp_direction='no_parallax';}
34this.direction=resp_direction;this.speed=''==resp_speed?this.defaultSpeed:parseFloat(resp_speed)/100.0;},_getTranslateObject:function(element)
35{var translate={type:'',matrix:[],x:0,y:0,z:0};$.each(this.transformCSSProps,function(i,prop)
36{var found=element.css(prop);if('string'!=typeof found||'none'==found)
37{return;}
38if(found.indexOf('matrix')>=0)
39{var matrixValues=found.match(/matrix.*\((.+)\)/)[1].split(', ');if(found.indexOf('matrix3d')>=0)
40{translate.type='3d';translate.matrix=matrixValues;translate.x=matrixValues[12];translate.y=matrixValues[13];translate.z=matrixValues[14];}
41else
42{translate.type='2d';translate.matrix=matrixValues;translate.x=matrixValues[4];translate.y=matrixValues[5];}
43return false;}
44else
45{translate.type='';var matchX=found.match(/translateX\((-?\d+\.?\d*px)\)/);if(matchX)
46{translate.x=parseInt(matchX[1],10);}
47var matchY=found.match(/translateY\((-?\d+\.?\d*px)\)/);if(matchY)
48{translate.y=parseInt(matchY[1],10);}}});return translate;}
48,_getTranslateMatrix:function(translateObj,changes)
49{var matrix='';$.each(changes,function(key,value)
50{translateObj[key]=value;});if(this.transform3d)
51{var matrix3d=this.matrix3dDef.slice(0);switch(translateObj.type)
52{case'2d':matrix3d[0]=translateObj.matrix[0];matrix3d[1]=translateObj.matrix[1];matrix3d[4]=translateObj.matrix[2];matrix3d[5]=translateObj.matrix[3];matrix3d[12]=translateObj.x;matrix3d[13]=translateObj.y;break;case'3d':matrix3d=translateObj.matrix.slice(0);matrix3d[12]=translateObj.x;matrix3d[13]=translateObj.y;matrix3d[14]=translateObj.z;break;default:matrix3d[12]=translateObj.x;matrix3d[13]=translateObj.y;break;}
53matrix='matrix3d('+matrix3d.join(', ')+')';}
54else if(this.transform)
55{var matrix2d=this.matrixDef.slice(0);switch(translateObj.type)
56{case'2d':matrix2d=translateObj.matrix.slice(0);matrix2d[4]=translateObj.x;matrix2d[5]=translateObj.y;break;case'3d':matrix2d[0]=translateObj.matrix[0];matrix2d[1]=translateObj.matrix[1];matrix2d[2]=translateObj.matrix[4];matrix2d[3]=translateObj.matrix[5];matrix2d[4]=translateObj.x;matrix2d[5]=translateObj.y;break;default:matrix2d[4]=translateObj.x;matrix2d[5]=translateObj.y;break;}
57matrix='matrix('+matrix2d.join(', ')+')';}
58return matrix;},_fetchProperties:function()
59{this._setParallaxProps();this.el.css($.avia_utilities.supported.transition+'transform','');this.winHeight=this.win.height();this.winWidth=this.win.width();if('background-image'==this.objectType)
60{this.elProperty.top=this.elBackgroundParent.offset().top;this.elProperty.height=this.elBackgroundParent.outerHeight();this.el.height(Math.ceil((this.winHeight*Math.abs(this.speed))+this.elProperty.height));}
61else
62{this.elProperty.top=this.elInner.offset().top;this.elProperty.left=this.elInner.offset().left;this.elProperty.height=this.elInner.outerHeight();this.elProperty.width=this.elInner.outerWidth();this.elProperty.bottom=this.elProperty.top+this.elProperty.height;this.elProperty.right=this.elProperty.left+this.elProperty.width;this.elProperty.distanceLeft=this.elProperty.right;this.elProperty.distanceRight=this.winWidth-this.elProperty.left;}
63this.elProperty.translateObj=this._getTranslateObject(this.el);this._parallaxScroll();},_onScroll:function(e)
64{var _self=this;if(!_self.ticking)
65{_self.ticking=true;window.requestAnimationFrame(_self._parallaxRequest.bind(_self));}},_inViewport:function(elTop,elRight,elBottom,elLeft,winTop,winBottom,winLeft,winRight)
66{return!(elTop>winBottom+10||elBottom<winTop-10||elLeft>winRight+10||elRight<winLeft-10);},_parallaxRequest:function(e)
67{var _self=this;setTimeout(_self._parallaxScroll.bind(_self),0);},_parallaxScroll:function(e)
68{if(('no_parallax'==this.direction||''==this.direction)&&!this.isTransformed)
69{this.ticking=false;return;}
70var winTop=this.win.scrollTop(),winLeft=this.win.scrollLeft(),winRight=winLeft+this.winWidth,winBottom=winTop+this.winHeight,scrollPos=0,matrix='';if('background-image'==this.objectType)
71{if(this.elProperty.top<winBottom&&winTop<=this.elProperty.top+this.elProperty.height)
72{scrollPos=Math.ceil((winBottom-this.elProperty.top)*this.speed);matrix=this._getTranslateMatrix(this.elProperty.translateObj,{y:scrollPos});this.el.css($.avia_utilities.supported.transition+'transform',matrix);}
73this.ticking=false;return;}
74if(('no_parallax'==this.direction||''==this.direction))
75{matrix=this._getTranslateMatrix(this.elProperty.translateObj,{x:0,y:0});this.el.css($.avia_utilities.supported.transition+'transform',matrix);this.ticking=false;this.isTransformed=false;return;}
76var scroll_px_toTop=Math.ceil(this.elProperty.top-winTop),scroll_px_el=Math.ceil(winBottom-this.elProperty.top),scrolled_pc_toTop=0,reduceDistanceX=0,transform={x:0,y:0};if(this.elProperty.top<this.winHeight)
77{reduceDistanceX=Math.ceil(this.winHeight-this.elProperty.top);}
78if(this.elProperty.top>winBottom)
79{scrolled_pc_toTop=0;scroll_px_el=0;}
80else
81{scrolled_pc_toTop=1-(scroll_px_toTop+reduceDistanceX)/this.winHeight;}
82switch(this.direction)
83{case'bottom_top':scrollPos=Math.ceil((scroll_px_el-reduceDistanceX)*this.speed);transform.y=-scrollPos;
83matrix=this._getTranslateMatrix(this.elProperty.translateObj,{y:-scrollPos});break;case'left_right':scrollPos=Math.ceil(this.elProperty.distanceRight*scrolled_pc_toTop*this.speed);transform.x=scrollPos;matrix=this._getTranslateMatrix(this.elProperty.translateObj,{x:scrollPos});break;case'right_left':scrollPos=Math.ceil(this.elProperty.distanceLeft*scrolled_pc_toTop*this.speed);transform.x=-scrollPos;matrix=this._getTranslateMatrix(this.elProperty.translateObj,{x:-scrollPos});break;default:break;}
84var elInViewport=this._inViewport(this.elProperty.top,this.elProperty.right,this.elProperty.bottom,this.elProperty.left,winTop,winBottom,winLeft,winRight),transformedInViewport=this._inViewport(this.elProperty.top+transform.y,this.elProperty.right+transform.x,this.elProperty.bottom+transform.y,this.elProperty.left+transform.x,winTop,winBottom,winLeft,winRight);if(elInViewport||transformedInViewport)
85{this.el.css($.avia_utilities.supported.transition+'transform',matrix);}
86this.ticking=false;this.isTransformed=true;}};$.fn.avia_parallax=function(options)
87{return this.each(function()
88{var obj=$(this);var self=obj.data('aviaParallax');if(!self)
89{self=obj.data('aviaParallax',new AviaObjectParallaxElement(options,this));}});};})(jQuery);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.