HEX
Server: Apache
System: Linux d8507.use1.stableserver.net 5.14.0-570.30.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 30 05:12:29 EDT 2025 x86_64
User: dacusvillerec (1045)
PHP: 8.2.32
Disabled: NONE
Upload Files
File: /home/dacusvillerec/public_html/wp-content/themes/exponent/js/vendor/begrid.min.js
!function(t,e,i){"function"==typeof define&&define.amd?define("begrid",e):"object"==typeof module&&module.exports?module.exports=e(i):t.BeGrid=e(i)}(window,function(n){"use strict";function t(t){null==t||n(t).hasClass("be-grid-initialized")||(this.init(t),o.load(function(){this.ele.isotope("layout")}.bind(this)))}var o=n(window);return t.prototype.init=function(t){null!=t&&(this.ele=n(t),this.setDefaultProps(),this.setLayout(),this.setGutter(),this.initGridAnimation(),this.grid(),this.initEvents(),this.filterItems())},t.prototype.initEvents=function(){o.on("load",function(){this.ele.isotope("layout")}.bind(this)),o.on("debouncedresize",function(){var t=this.ele.find("audio, video"),e=this.ele.find(".be-slider");this.grid(),0<t.length&&t.each(function(){var t=n(this).data().mediaelementplayer;"object"==typeof t&&(t.setPlayerSize(),t.setControlsSize())}),0<e.length&&(e.each(function(){var t=n(this);t.hasClass("flickity-enabled")&&t.flickity("reposition")}),this.ele.isotope("layout"))}.bind(this))},t.prototype.setDefaultProps=function(){this.cols=3,this.gutter=0,this.elementsToReveal=null,this.animationType="revealAllAtOnce",this.layout="masonry"},t.prototype.setGutter=function(){this.gutter=parseInt(this.ele.attr("data-gutter"))||0},t.prototype.setLayout=function(){"metro"===this.ele.attr("data-layout")&&(this.layout="metro")},t.prototype.setCols=function(){var t=parseInt(this.ele.attr("data-cols"))||3,e=o.width();if(1024<e)this.cols=t;else if(959<e)switch(t){case 1:this.cols=1;break;case 2:this.cols=2;break;case 3:default:this.cols=3}else 767<e?this.cols=1==t?1:2:null!=this.ele.attr("data-mobile-cols")?this.cols=parseInt(this.ele.attr("data-mobile-cols")):this.cols=1},t.prototype.initGridAnimation=function(){this.animationType="1"===this.ele.attr("data-scroll-reveal")?"scrollReveal":"revealAllAtOnce",this.elementsToReveal=this.ele.find(".be-col"),this.addAnimationClass(),"scrollReveal"===this.animationType&&o.on("scroll",function(){this.triggerScrollReveal()}.bind(this))},t.prototype.addAnimationClass=function(){var t=this.ele.attr("data-animation-target")||".be-col",e=this.ele.attr("data-animation")||"be-col-hide";this.ele.find(t).addClass(e)},t.prototype.triggerScrollReveal=function(){var t;"scrollReveal"===this.animationType&&0<this.elementsToReveal.length&&(0<(t=this.elementsToReveal.filter(function(){return n(this).isVisible(-100)})).length&&(t.each(function(t,e){var i=n(e),s=null==this.ele.attr("data-animation")?"be-col-visible":"be-start-animation",e=this.ele.attr("data-animation-target");null!=e&&(i=i.find(e)),i.css("transition-delay",150*t+"ms"),i.addClass(s)}.bind(this)),this.elementsToReveal=this.elementsToReveal.not(t)))},t.prototype.filterItems=function(){"1"===this.ele.attr("data-filter-items")&&this.ele.parent().on("click",".sort-items",function(t){var e,i=n(t.currentTarget).data("id"),s=n([]);n(t.currentTarget).hasClass("current_choice")||(this.ele.parent().find(".sort-items").removeClass("current_choice"),n(t.currentTarget).addClass("current_choice"),(e=this.ele.find(".be-col")).css({transform:"scale(0)",transition:"all 0.3s ease"}),setTimeout(function(){e.find(".be-start-animation").css("transition-delay",""),e.css({transform:"",transition:""}),this.ele.isotope({filter:function(){var t=n(this).data("category-names");if("all"===i||-1<t.indexOf(i))return s=s.add(n(this)),!0},transitionDuration:0}),s.find(".be-start-animation").removeClass("be-start-animation"),this.elementsToReveal=s,setTimeout(function(){"scrollReveal"===this.animationType?this.triggerScrollReveal():this.revealAllAtOnce()}.bind(this),0)}.bind(this),300))}.bind(this))},t.prototype.revealAllAtOnce=function(){"revealAllAtOnce"===this.animationType&&0<this.elementsToReveal.length&&(this.elementsToReveal.each(function(t,e){var i=n(e),s=null==this.ele.attr("data-animation")?"be-col-visible":"be-start-animation",e=this.ele.attr("data-animation-target");null!=e&&(i=i.find(e)),i.css("transition-delay",150*t+"ms"),i.addClass(s)}.bind(this)),this.elementsToReveal=n([]))},t.prototype.grid=function(){this.setCols(),this.setWidth(),this.setGiantCells(),this.renderLayout()},t.prototype.setWidth=function(){this.ele.width("");var t,e=this.ele.width(),i=o.width(),s=this.ele.find(".be-col");console.log(e);var e=Math.floor(e/this.cols)*this.cols+this.cols;console.log(e),this.ele.width(e),e=e/this.cols,"masonry"==this.layout||767<i&&0<(t=s.filter(function(){return n(this).hasClass("be-double-width-cell")||n(this).hasClass("be-double-width-height-cell")})).length&&(s=s.not(t),t.outerWidth(2*e)),s.outerWidth(e)},t.prototype.setGiantCells=function(){var s,a,l,t,e,i;"metro"==this.layout&&(i=isNaN(parseFloat(this.ele.attr("data-aspect-ratio")))?1:parseFloat(this.ele.attr("data-aspect-ratio")),s=this.ele.width()/this.cols-this.gutter,a=o.width(),l=s/i,l=Math.round(100*l)/100,t=this.ele.find(".be-double-width-cell"),e=this.ele.find(".be-double-height-cell"),i=this.ele.find(".be-double-width-height-cell"),0<t.length&&t.each(function(t,e){var i=n(e),e=767<a?l/(2*s+this.gutter):l/s;isNaN(e)||(e*=100,i.find(".be-grid-placeholder").css("padding-bottom",e+"%"))}.bind(this)),0<e.length&&e.each(function(t,e){var i=n(e),e=(2*l+this.gutter)/s;isNaN(e)||(e*=100,i.find(".be-grid-placeholder").css("padding-bottom",e+"%"))}.bind(this)),0<i.length&&i.each(function(t,e){var i=n(e),e=767<a?(2*l+this.gutter)/(2*s+this.gutter):(2*l+this.gutter)/s;isNaN(e)||(e*=100,i.find(".be-grid-placeholder").css("padding-bottom",e+"%"))}.bind(this)))},t.prototype.renderLayout=function(){var t=this.ele.width()/this.cols;this.ele.isotope({isInitLayout:!1,itemSelector:".be-col",resize:!1,masonry:{columnWidth:t}}),this.ele.on("layoutComplete",function(){this.ele.hasClass("be-grid-initialized")||(this.ele.addClass("be-grid-initialized"),setTimeout(function(){"scrollReveal"===this.animationType?this.triggerScrollReveal():this.revealAllAtOnce(),BeLazyLoad.lazyLoad()}.bind(this),0))}.bind(this)),this.ele.isotope()},t},jQuery);