/home/arranoyd/telegastro/wp-content/plugins/Ultimate_VC_Addons/assets/min-js/fixto.min.js
var fixto=function(s,t,r){var i,h=(i={getAll:function(t){return r.defaultView.getComputedStyle(t)},get:function(t,i){return this.getAll(t)[i]},toFloat:function(t){return parseFloat(t,10)||0},getFloat:function(t,i){return this.toFloat(this.get(t,i))},_getAllCurrentStyle:function(t){return t.currentStyle}},r.documentElement.currentStyle&&(i.getAll=i._getAllCurrentStyle),i),o=function(){function t(t){this.element=t,this.replacer=r.createElement("div"),this.replacer.style.visibility="hidden",this.hide(),t.parentNode.insertBefore(this.replacer,t)}return t.prototype={replace:function(){var t=this.replacer.style,i=h.getAll(this.element);t.width=this._width(),t.height=this._height(),t.marginTop=i.marginTop,t.marginBottom=i.marginBottom,t.marginLeft=i.marginLeft,t.marginRight=i.marginRight,t.cssFloat=i.cssFloat,t.styleFloat=i.styleFloat,t.position=i.position,t.top=i.top,t.right=i.right,t.bottom=i.bottom,t.left=i.left,t.display=i.display},hide:function(){this.replacer.style.display="none"},_width:function(){return this.element.getBoundingClientRect().width+"px"},_widthOffset:function(){return this.element.offsetWidth+"px"},_height:function(){return this.element.getBoundingClientRect().height+"px"},_heightOffset:function(){return this.element.offsetHeight+"px"},destroy:function(){for(var t in s(this.replacer).remove(),this)this.hasOwnProperty(t)&&(this[t]=null)}},r.documentElement.getBoundingClientRect().width||(t.prototype._width=t.prototype._widthOffset,t.prototype._height=t.prototype._heightOffset),{MimicNode:t,computedStyle:h}}();function e(){this._vendor=null}e.prototype={_vendors:{webkit:{cssPrefix:"-webkit-",jsPrefix:"Webkit"},moz:{cssPrefix:"-moz-",jsPrefix:"Moz"},ms:{cssPrefix:"-ms-",jsPrefix:"ms"},opera:{cssPrefix:"-o-",jsPrefix:"O"}},_prefixJsProperty:function(t,i){return t.jsPrefix+i[0].toUpperCase()+i.substr(1)},_prefixValue:function(t,i){return t.cssPrefix+i},_valueSupported:function(t,i,e){try{return e.style[t]=i,e.style[t]===i}catch(t){return!1}},propertySupported:function(t){return void 0!==r.documentElement.style[t]},getJsProperty:function(t){if(this.propertySupported(t))return t;if(this._vendor)return this._prefixJsProperty(this._vendor,t);var i;for(var e in this._vendors)if(i=this._prefixJsProperty(this._vendors[e],t),this.propertySupported(i))return this._vendor=this._vendors[e],i;return null},getCssValue:function(t,i){var e,o=r.createElement("div"),n=this.getJsProperty(t);if(this._valueSupported(n,i,o))return i;if(this._vendor&&(e=this._prefixValue(this._vendor,i),this._valueSupported(n,e,o)))return e;for(var s in this._vendors)if(e=this._prefixValue(this._vendors[s],i),this._valueSupported(n,e,o))return this._vendor=this._vendors[s],e;return null}};var l,n=new e,p=n.getJsProperty("transform");var d,a=n.getCssValue("position","sticky"),f=n.getCssValue("position","fixed");function c(t,i,e){this.child=t,this._$child=s(t),this.parent=i,this.options={className:"fixto-fixed",top:0},this._setOptions(e)}function u(t,i,e){c.call(this,t,i,e),this._replacer=new o.MimicNode(t),this._ghostNode=this._replacer.replacer,this._saveStyles(),this._saveViewportHeight(),this._proxied_onscroll=this._bind(this._onscroll,this),this._proxied_onresize=this._bind(this._onresize,this),this.start()}function _(t,i,e){c.call(this,t,i,e),this.start()}"Microsoft Internet Explorer"===navigator.appName&&(d=parseFloat(navigator.appVersion.split("MSIE")[1])),c.prototype={_mindtop:function(){var t=0;if(this._$mind)for(var i,e,o=0,n=this._$mind.length;o<n;o++)if((e=(i=this._$mind[o]).getBoundingClientRect()).height)t+=e.height;else{var s=h.getAll(i);t+=i.offsetHeight+h.toFloat(s.marginTop)+h.toFloat(s.marginBottom)}return t},stop:function(){this._stop(),this._running=!1},start:function(){this._running||(this._start(),this._running=!0)},destroy:function(){for(var t in this.stop(),this._destroy(),this._$child.removeData("fixto-instance"),this)this.hasOwnProperty(t)&&(this[t]=null)},_setOptions:function(t){s.extend(this.options,t),this.options.mind&&(this._$mind=s(this.options.mind)),this.options.zIndex&&(this.child.style.zIndex=this.options.zIndex)},setOptions:function(t){this._setOptions(t),this.refresh()},_stop:function(){},_start:function(){},_destroy:function(){},refresh:function(){}},u.prototype=new c,s.extend(u.prototype,{_bind:function(t,i){return function(){return t.call(i)}},_toresize:8===d?r.documentElement:t,_onscroll:function(){if(this._scrollTop=r.documentElement.scrollTop||r.body.scrollTop,this._parentBottom=this.parent.offsetHeight+this._fullOffset("offsetTop",this.parent),!1!==this.options.mindBottomPadding&&(this._parentBottom-=h.getFloat(this.parent,"paddingBottom")),this.fixed){if(this._scrollTop>this._parentBottom||this._scrollTop<this._fullOffset("offsetTop",this._ghostNode)-this.options.top-this._mindtop())return void this._unfix();this._adjust()}else{var t=h.getAll(this.child);this._scrollTop<this._parentBottom&&this._scrollTop>this._fullOffset("offsetTop",this.child)-this.options.top-this._mindtop()&&this._viewportHeight>this.child.offsetHeight+h.toFloat(t.marginTop)+h.toFloat(t.marginBottom)&&(this._fix(),this._adjust())}},_adjust:function(){var t=0,i=this._mindtop(),e=0,o=h.getAll(this.child),n=null;l&&(n=this._getContext())&&(0<n.getBoundingClientRect().top?t-=n.getBoundingClientRect().top:t=Math.abs(n.getBoundingClientRect().top)),0<(e=this._parentBottom-this._scrollTop-(this.child.offsetHeight+h.toFloat(o.marginBottom)+i+this.options.top))&&(e=0),this.child.style.top=e+i+t+this.options.top-h.toFloat(o.marginTop)+"px"},_fullOffset:function(t,i,e){for(var o=i[t],n=i.offsetParent;null!==n&&n!==e;)o+=n[t],n=n.offsetParent;return o},_getContext:function(){for(var t,i=this.child,e=null;!e;){if((t=i.parentNode)===r.documentElement)return null;if("none"!==h.getAll(t)[p]){e=t;break}i=t}return e},_fix:function(){var t=this.child,i=t.style,e=h.getAll(t),o=t.getBoundingClientRect().left,n=e.width;if(this._saveStyles(),r.documentElement.currentStyle&&(n=t.offsetWidth-(h.toFloat(e.paddingLeft)+h.toFloat(e.paddingRight)+h.toFloat(e.borderLeftWidth)+h.toFloat(e.borderRightWidth))+"px"),l){var s=this._getContext();s&&(o=t.getBoundingClientRect().left-s.getBoundingClientRect().left)}this._replacer.replace(),i.left=o-h.toFloat(e.marginLeft)+"px",i.width=n,i.position="fixed",i.top=this._mindtop()+this.options.top-h.toFloat(e.marginTop)+"px",this._$child.addClass(this.options.className),this.fixed=!0},_unfix:function(){var t=this.child.style;this._replacer.hide(),t.position=this._childOriginalPosition,t.top=this._childOriginalTop,t.width=this._childOriginalWidth,t.left=this._childOriginalLeft,this._$child.removeClass(this.options.className),this.fixed=!1},_saveStyles:function(){var t=this.child.style;this._childOriginalPosition=t.position,this._childOriginalTop=t.top,this._childOriginalWidth=t.width,this._childOriginalLeft=t.left},_onresize:function(){this.refresh()},_saveViewportHeight:function(){this._viewportHeight=t.innerHeight||r.documentElement.clientHeight},_stop:function(){this._unfix(),s(t).unbind("scroll",this._proxied_onscroll),s(this._toresize).unbind("resize",this._proxied_onresize)},_start:function(){this._onscroll(),s(t).bind("scroll",this._proxied_onscroll),s(this._toresize).bind("resize",this._proxied_onresize)},_destroy:function(){this._replacer.destroy()},refresh:function(){this._saveViewportHeight(),this._unfix(),this._onscroll()}}),_.prototype=new c,s.extend(_.prototype,{_start:function(){var t=h.getAll(this.child);this._childOriginalPosition=t.position,this._childOriginalTop=t.top,this.child.style.position=a,this.refresh()},_stop:function(){this.child.style.position=this._childOriginalPosition,this.child.style.top=this._childOriginalTop},refresh:function(){this.child.style.top=this._mindtop()+this.options.top+"px"}});var g=function(t,i,e){return a&&!e||a&&e&&!1!==e.useNativeSticky?new _(t,i,e):f?(void 0===l&&(o=!1,n=r.createElement("div"),s=r.createElement("div"),n.appendChild(s),n.style[p]="translate(0)",n.style.marginTop="10px",n.style.visibility="hidden",s.style.position="fixed",s.style.top=0,r.body.appendChild(n),0<s.getBoundingClientRect().top&&(o=!0),r.body.removeChild(n),l=o),new u(t,i,e)):"Neither fixed nor sticky positioning supported";var o,n,s};return d<8&&(g=function(){return"not supported"}),s.fn.fixTo=function(i,e){var o=s(i),n=0;return this.each(function(){var t=s(this).data("fixto-instance");t?t[i].call(t,e):s(this).data("fixto-instance",g(this,o[n],e));n++})},{FixToContainer:u,fixTo:g,computedStyle:h,mimicNode:o}}(window.jQuery,window,document);