PageSourceSearch

https://olana.org/wp-content/plugins/fusion-builder/assets/js/min/general/fusion-container.js?ver=3.16.2

js olana.org collected 2026-10-02 03:05:35 UTC 14,697 bytes, 1 lines download raw bytes

1function initStackingScrollSections(e){var t=e?jQuery(".post-preview.post-content").find(".awb-stacking-sections"):jQuery(".awb-stacking-sections");t.length&&t.each(function(){var e,t=jQuery(this),n=t.children(".awb-stacking-section-element"),i=t.find(".fusion-scroll-section-link"),o=0;function s(){var e=t.find(".fusion-scroll-section-nav ul");o=getScrollSectionTopOffset(),t.css("--awb-stacking-offset",o+"px"),e.length&&t.css("--awb-stacking-nav-half",e.outerHeight()/2+"px"),0==fusionContainerVars.container_hundred_percent_height_mobile&&Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?t.addClass("awb-stacking-disabled"):t.removeClass("awb-stacking-disabled")}t.data("stacking-init")||(t.data("stacking-init",!0),s(),jQuery(window).on("resize",s),jQuery(document).on("sticky_kit:stick sticky_kit:unstick",s),i.length&&"undefined"!=typeof IntersectionObserver&&(e=new IntersectionObserver(function(){var e=0,t=window.innerHeight/2;n.each(function(n){var i=this.getBoundingClientRect();i.top<=t&&i.bottom>=t&&(e=n)}),i.removeClass("active"),i.eq(e).addClass("active")},{threshold:[0,.25,.5,.75,1]}),n.each(function(){e.observe(this)})),i.on("click",function(e){var i=jQuery(this).closest("li").index(),s=t.offset().top-o;e.preventDefault(),n.slice(0,i).each(function(){s+=jQuery(this).outerHeight()}),window.scrollTo({top:s,behavior:"smooth"})}))})}function fusionInitStickyContainers(){"function"==typeof jQuery.fn.stick_in_parent&&jQuery(".fusion-sticky-container").each(function(){fusionInitSticky(jQuery(this))})}function fusionInitSticky(e){var t=void 0===e.attr("data-transition-offset")?0:parseFloat(e.attr("data-transition-offset")),n=void 0===e.attr("data-sticky-offset")?0:e.attr("data-sticky-offset"),i=void 0!==e.attr("data-scroll-offset")&&parseFloat(e.attr("data-scroll-offset")),o={sticky_class:"fusion-container-stuck",bottoming:!0,offset_top:n,transition_offset:t,clone:!1},s="data-sticky-medium-visibility";jQuery("body").hasClass("fusion-disable-sticky")?e.data("sticky_kit")&&e.trigger("sticky_kit:detach"):"object"!=typeof fusion||"function"!=typeof fusion.isLarge||(fusion.isLarge()?s="data-sticky-large-visibility":fusion.isSmall()&&(s="data-sticky-small-visibility"),void 0!==e.attr(s)&&e.attr(s))?e.data("sticky_kit")||(i&&(o.scroll_transition=i),e.closest(".fusion-tb-header").length||e.closest(".fusion-tb-page-title-bar").length?(o.parent="#wrapper",o.bottoming=!1):e.closest(".fusion-content-tb").length?o.parent=".fusion-content-tb":e.closest(".fusion-builder-live-editor").length?o.parent="#fusion_builder_container":e.parent().parent(".post-content").length?o.parent=".post-content":e.hasClass("awb-sticky-content")&&(o.parent="#wrapper"),"string"==typeof e.attr("data-sticky-parent")&&(o.parent=e.attr("data-sticky-parent")),"string"==typeof e.attr("data-sticky-bottoming")&&(o.bottoming=e.attr("data-sticky-bottoming")),jQuery("body").hasClass("fusion-builder-live")||void 0===e.attr("data-sticky-height-transition")||(o.clone=!0),e.stick_in_parent(o)):e.data("sticky_kit")&&e.trigger("sticky_kit:detach")}function awbContainerIsOutOfFlow(e){var t="medium";return!!e.hasClass("fusion-absolute-container")&&("object"==typeof fusion&&"function"==typeof fusion.isLarge&&(fusion.isLarge()?t="large":fusion.isSmall()&&(t="small")),e.hasClass("fusion-absolute-position-"+t))}function fusionGetStickyOffset(e){var t=0,n=jQuery(".fusion-container-stuck:not( .side-header-wrapper )");return n.length?(n.each(function(){var n=jQuery(this),i=n.position().top+n.outerHeight(!0);if(!fusionIsWholeElementInViewport(n[0]))return;const o=n.closest("#side-header");(!o.length||"static"===o.css("position")&&o.hasClass("fusion-tb-header"))&&(n.closest(".off-canvas-content").length||e&&awbContainerIsOutOfFlow(n)||i>t&&(t=i))}),t):t}function fusionIsWholeElementInViewport(e){const t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight;return!(100>Math.floor(100-(0<=t.top?0:t.top)/+-t.height*100)||100>Math.floor(100-(t.bottom-n)/t.height*100))}function getScrollSectionTopOffset(){return jQuery(".fusion-tb-header").length?fusionGetStickyOffset(!0)||fusion.getAdminbarHeight():(Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0))+fusion.getAdminbarHeight()}
1function hasTransformedAncestor(e){for(var t,n=e.parentElement;n&&n!==document.body;){if("none"!==(t=getComputedStyle(n)).transform||"none"!==t.perspective||"none"!==t.filter||t.backdropFilter&&"none"!==t.backdropFilter||/transform|perspective|filter/.test(t.willChange))return!0;n=n.parentElement}return!1}function getScrollableParent(e,t,n){for(var i,o=e;o&&o!==t&&o!==document.body;){if(o.scrollHeight>o.clientHeight&&("auto"===(i=getComputedStyle(o)).overflowY||"scroll"===i.overflowY)&&(0<n&&o.scrollTop+o.clientHeight<o.scrollHeight-1||0>n&&0<o.scrollTop))return o;o=o.parentElement}return null}function initFullScrollSections(e){var t=e?jQuery(".post-preview.post-content").find(".awb-full-sections"):jQuery(".awb-full-sections");t.length&&"undefined"!=typeof gsap&&"undefined"!=typeof ScrollTrigger&&(gsap.registerPlugin(ScrollTrigger),jQuery(document).off(".awbFullSectionsSticky").on("sticky_kit:stick.awbFullSectionsSticky sticky_kit:unstick.awbFullSectionsSticky",function(){clearTimeout(initFullScrollSections.stickyRefreshTimer),initFullScrollSections.stickyRefreshTimer=setTimeout(function(){ScrollTrigger.refresh()},100)}),initFullScrollSections.marqueeRefreshBound||(initFullScrollSections.marqueeRefreshBound=!0,ScrollTrigger.addEventListener("refresh",function(){jQuery(".awb-full-sections").find('.awb-carousel[data-layout="marquee"]').each(function(){this.swiper&&(this.swiper.animating=!1,this.swiper.autoplay.stop(),this.swiper.autoplay.start())})})),t.each(function(){var e=this,t=jQuery(e),n=String(t.data("animation")),i=parseInt(t.data("speed"),10)||800,o=t.children(".awb-full-section").toArray(),s=t.find(".fusion-scroll-section-link"),r=o.length,a="rtl"===jQuery("html").attr("dir"),c=0===n.indexOf("scroll-"),l=-1!==n.indexOf("-free"),u=-1!==n.indexOf("-left"),d={xPercent:0,yPercent:0,x:0,y:0,z:0,scale:1,duration:1},f={fade:{prev:{},next:{opacity:0},fadeEase:"sine.inOut"},slide:{prev:{yPercent:-100,opacity:0},next:{yPercent:100,opacity:0}},"slide-right":{prev:{xPercent:100,opacity:0},next:{xPercent:-100,opacity:0}},"slide-left":{prev:{xPercent:-100,opacity:0},next:{xPercent:100,opacity:0}},stack:{prev:{y:60,z:-30,scale:.7,opacity:0},next:{yPercent:100}},zoom:{prev:{scale:1.3,opacity:0}
1,next:{scale:.7,opacity:0}},"slide-zoom-out":{prev:{yPercent:-100,scale:1.5,opacity:0},next:{yPercent:100,scale:1.5,opacity:0}},"slide-zoom-in":{prev:{yPercent:-100,scale:.8,opacity:0},next:{yPercent:100,scale:.8,opacity:0}}},h={"slide-right":"slide-left","slide-left":"slide-right"},p=f[a&&h[n]?h[n]:n]||f.slide,g=jQuery.extend({duration:1},p.prev),y=g.opacity,m=!c&&!p.next.xPercent&&!p.next.yPercent,w=0==fusionContainerVars.container_hundred_percent_height_mobile?"(min-width: "+(parseInt(fusionContainerVars.content_break_point,10)+1)+"px)":"all",b=null,v=-1,k={animating:!1,tween:null,direction:0,cooldownEnd:0,lastWheelTime:0,settleTimer:0};function S(e){var t;e!==v&&(v=e,s.removeClass("active").eq(e).addClass("active"),jQuery(o).removeClass("awb-full-section-active"),(t=jQuery(o[e]).addClass("awb-full-section-active").find(".fusion-container-anchor").attr("id")||o[e].id)&&function(e){if(!e.length)return;e.hasClass("awb-menu__main-a")?(e.parents(".awb-menu__main-ul").find("li.menu-item.current-menu-item").removeClass("current-menu-item"),e.closest(".menu-item").addClass("current-menu-item")):e.addClass("awb-active")}(jQuery('a[href="#'+t+'"]')))}function j(e){return b.start+(b.end-b.start)*(e/(r-1))}function _(e,t){b?t?C(e):window.scrollTo({top:j(e),behavior:"auto"}):o[e].scrollIntoView({behavior:t?"smooth":"auto"})}function Q(e){var t=e.closest(".awb-full-section");return t.length?jQuery.inArray(t[0],o):-1}function C(e,t){var n={y:window.scrollY||document.documentElement.scrollTop},o=j(Math.max(0,Math.min(r-1,e)));k.direction=t||(o>n.y?1:-1),k.animating=!0,k.tween=gsap.to(n,{y:o,duration:Math.max(.4,i/1e3),ease:"power3.out",onUpdate:function(){window.scrollTo(0,n.y)},onComplete:function(){k.animating=!1,k.cooldownEnd=performance.now()+400}})}2>r||t.data("full-sections-init")||(t.data("full-sections-init",!0),delete g.opacity,a&&c&&(u=!u),t.wrap('<div class="awb-full-sections-wrap'+(t.closest(".width-100").length||t.find(".fusion-fullwidth").first().hasClass("hundred-percent-fullwidth")?" awb-full-sections-wrap--100":"")+'"></div>'),t.addClass("awb-full-sections-disabled"),gsap.matchMedia().add(w,function(){var s,a,f;if(t.removeClass("awb-full-sections-disabled"),c?gsap.set(o,{xPercent:function(e){return(u?-100:100)*e}}):(p.prev.filter&&gsap.set(o,{filter:"brightness(1)"}),"fade"===n&&gsap.set(o,{zIndex:function(e){return e+1}}),gsap.set(o.slice(1),p.next)),a={trigger:e,start:function(){var t=getScrollSectionTopOffset();return e.style.height="calc(100vh - "+t+"px)","top top+="+t},end:function(){return"+="+(r-1)*e.offsetHeight},pin:!0,pinType:hasTransformedAncestor(e)?"transform":"fixed",scrub:!0,invalidateOnRefresh:!0,onUpdate:function(e){var t=e.progress*(r-1),n=Math.round(t),i=0<e.direction?1:-1;S(n),!l&&!k.animating&&400>performance.now()-k.lastWheelTime&&.02<Math.abs(t-n)&&(clearTimeout(k.settleTimer),k.settleTimer=setTimeout(function(){b&&!k.animating&&C(Math.round(b.progress*(r-1)),i)},180))}},l||(a.snap={snapTo:function(e,t){var n,i=1/(r-1),o=Math.round(t.progress/i)*i;return Math.abs(t.progress-o)<.05*i?o:(n=0<t.direction?(Math.floor(t.progress/i)+1)*i:(Math.ceil(t.progress/i)-1)*i,Math.max(0,Math.min(1,n)))},duration:{min:.15,max:i/1e3},delay:0,ease:"power3.out"}),s=gsap.timeline({defaults:{ease:"none"},scrollTrigger:a}),c)s.to(o,{xPercent:function(e){return(u?-100:100)*(e-(r-1))},duration:r-1},0);else for(f=0;f<r-1;f++)s.to(o[f+1],d,f),s.to(o[f+1],{opacity:1,duration:1,ease:p.fadeEase||"power2.out"},f),jQuery.isEmptyObject(p.prev)||s.to(o[f],g,f),void 0!==y&&s.to(o[f],{opacity:y,duration:1,ease:"power2.in"},f);return b=s.scrollTrigger,ScrollTrigger.create({trigger:t.closest(".awb-full-sections-wrap")[0],start:"top bottom",end:"bottom top",onToggle:function(e){t.toggleClass("awb-full-sections-active",e.isActive)}}),t.toggleClass("awb-full-sections--stacked",m).addClass("awb-full-sections-ready"),v=-1,S(0),function(){clearTimeout(k.settleTimer),b=null,t.removeClass("awb-full-sections-ready awb-full-sections-active").addClass("awb-full-sections-disabled"),e.style.height=""}}),window.addEventListener("wheel",function(t){var n,i,o,s=b;if(k.lastWheelTime=performance.now(),clearTimeout(k.settleTimer),!l&&s&&t.deltaY&&!((o=s.scroll())<s.start-1||o>s.end+1)&&!(1===(n=0<t.deltaY?1:-1)&&.999<=s.progress||-1===n&&.001>=s.progress)&&(k.animating||!e.contains(t.target)||!getScrollableParent(t.target,e,t.deltaY))){if(t.preventDefault(),k.animating){if(n===k.direction)return;k.tween&&k.tween.kill(),k.animating=!1}else if(performance.now()<k.cooldownEnd&&60>
1Math.abs(t.deltaY))return;i=s.progress*(r-1),C(1===n?Math.floor(i+.02)+1:Math.ceil(i-.02)-1)}},{passive:!1}),s.on("click",function(e){e.preventDefault(),_(jQuery(this).closest("li").index(),!0)}),jQuery('a[href^="#"]').on("click.awbFullSections",function(e){var n=jQuery(this).attr("href"),i="#"!==n?t.find(n):jQuery(),o=i.length?Q(i):-1;-1!==o&&(e.preventDefault(),_(o,!0))}),window.location.hash&&t.find(window.location.hash).length&&setTimeout(function(){var e=Q(t.find(window.location.hash));-1!==e&&_(e,!1)},150))}))}function initScrollingSections(e){initStackingScrollSections(e),initFullScrollSections(e),jQuery(".hundred-percent-height").length&&(setNonScrollingSectionHeights(),jQuery(window).on("resize",setNonScrollingSectionHeights))}function setNonScrollingSectionHeights(){var e,t=jQuery(".hundred-percent-height.non-hundred-percent-height-scrolling");t.length&&0==fusionContainerVars.container_hundred_percent_height_mobile&&(Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?(t.css("height","auto"),t.find(".fusion-fullwidth-center-content").css("height","auto")):(e=getScrollSectionTopOffset(),t.css("height","calc(100vh - "+e+"px)"),t.find(".fusion-fullwidth-center-content").css("height","")))}jQuery(window).on("load fusion-element-render-fusion_builder_container resize",function(e,t){var n=void 0!==t?jQuery('div[data-cid="'+t+'"]').find(".fullwidth-faded"):jQuery(".fullwidth-faded"),i=void 0!==t?jQuery('div[data-cid="'+t+'"]').find(".hundred-percent-height"):jQuery(".hundred-percent-height"),o=Number(fusionContainerVars.is_sticky_header_transparent)||"function"!=typeof getStickyHeaderHeight?0:getStickyHeaderHeight(!0),s=fusion.getAdminbarHeight(),r=jQuery("body").hasClass("fusion-builder-live")&&!jQuery("body").hasClass("fusion-builder-preview-mode"),a=o+s;n.fusionScroller({type:"fading_blur"}),i.css("min-height","").css("height",""),i.find(".fusion-fullwidth-center-content").css("min-height",""),0==fusionContainerVars.container_hundred_percent_height_mobile&&Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")?(i.css("height","auto"),r&&(i.css("min-height","0"),i.find(".fusion-fullwidth-center-content").css("min-height","0"))):(i.css("height","calc(100vh - "+a+"px)"),r&&(i.css("min-height","calc(100vh - "+a+"px)"),i.find(".fusion-fullwidth-center-content").css("min-height","calc(100vh - "+a+"px)")))}),jQuery(document).ready(function(){var e;initScrollingSections(),fusionInitStickyContainers(),!jQuery("body").hasClass("fusion-builder-live")&&"object"==typeof cssua&&"string"==typeof cssua.ua.safari&&16>parseInt(cssua.ua.safari)&&(e=jQuery(".awb-sticky, .mobile-sticky-tabs, .sticky-tabs")).length&&(jQuery("#boxed-wrapper").addClass("safari-overflow"),e.each(function(){jQuery(this).parents(".fusion-fullwidth").addClass("has-sticky")})),Modernizr.mq("only screen and (max-width: "+fusionContainerVars.content_break_point+"px)")&&jQuery(".fullwidth-faded").each(function(){var e=jQuery(this).css("background-image"),t=jQuery(this).css("background-color");jQuery(this).parent().css("--awb-background-image",e),jQuery(this).parent().css("--awb-background-color",t),jQuery(this).remove()})}),jQuery(window).on("fusion-reinit-sticky",function(e,t){var n=void 0!==t&&jQuery('div[data-cid="'+t+'"] .fusion-fullwidth');n&&n.length&&(n.trigger("sticky_kit:detach"),fusionInitSticky(n))}),jQuery(window).on("fusion-sticky-header-reinit fusion-resize-horizontal",function(){fusionInitStickyContainers()}),jQuery("body").on("avada-studio-preview-done",function(){initScrollingSections(!0)});

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.