/**handles:responsive-lightbox-infinite-scroll,responsive-lightbox,taxopress-frontend-js,__ytprefs__**/ (()=>{var t,t,n=Object.defineProperty,d=Object.getOwnPropertySymbols,u=Object.prototype.hasOwnProperty,p=Object.prototype.propertyIsEnumerable,f=(t,e,i)=>e in t?n(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,t,e,o,s,i,l,r,a,h,c,t,g,r,h,t,t,t=((t=window).jQueryBridget=((t,e)=>{let i=t.console,h=void 0===i?function(){}:function(t){i.error(t)};function n(l,o,a){function i(t,n,o){let s,r=`$().${l}("${n}")`;return t.each(function(t,e){var e=a.data(e,l),i,i;e?(i=e[n])&&"_"!=n.charAt(0)?(i=i.apply(e,o),s=void 0===s?i:s):h(r+" is not a valid method"):h(l+" not initialized. Cannot call method "+r)}),void 0!==s?s:t}function n(t,n){t.each(function(t,e){let i=a.data(e,l);i?(i.option(n),i._init()):(i=new o(e,n),a.data(e,l,i))})}(a=a||e||t.jQuery)&&(o.prototype.option||(o.prototype.option=function(t){t&&(this.options=Object.assign(this.options||{},t))}),a.fn[l]=function(t,...e){return"string"==typeof t?i(this,t,e):(n(this,t),this)})}return n})(t,t.jQuery),(void 0!==window?window:void 0).EvEmitter=((t=O.prototype).on=function(t,e){var i,i;return t&&e&&((i=(i=this._events=this._events||{})[t]=i[t]||[]).includes(e)||i.push(e)),this},t.once=function(t,e){var i;return t&&e&&(this.on(t,e),((i=this._onceEvents=this._onceEvents||{})[t]=i[t]||{})[e]=!0),this},t.off=function(t,e){var t=this._events&&this._events[t],e;return t&&t.length&&-1!=(e=t.indexOf(e))&&t.splice(e,1),this},t.emitEvent=function(t,e){let i=this._events&&this._events[t];if(i&&i.length){i=i.slice(0),e=e||[];var n=this._onceEvents&&this._onceEvents[t],o;for(o of i)n&&n[o]&&(this.off(t,o),delete n[o]),o.apply(this,e)}return this},t.allOff=function(){return delete this._events,delete this._onceEvents,this},O),(t=window).fizzyUIUtils=(e=>{let n={extend:function(t,e){return Object.assign(t,e)},modulo:function(t,e){return(t%e+e)%e},makeArray:function(t){return Array.isArray(t)?t:null==t?[]:"object"==typeof t&&"number"==typeof t.length?[...t]:[t]},removeFrom:function(t,e){var e=t.indexOf(e);-1!=e&&t.splice(e,1)},getParent:function(t,e){for(;t.parentNode&&t!=document.body;)if((t=t.parentNode).matches(e))return t},getQueryElement:function(t){return"string"==typeof t?document.querySelector(t):t},handleEvent:function(t){var e="on"+t.type;this[e]&&this[e](t)},filterFindElements:function(t,i){return(t=n.makeArray(t)).filter(t=>t instanceof HTMLElement).reduce((t,e)=>{if(!i)return t.push(e),t;e.matches(i)&&t.push(e);var e=e.querySelectorAll(i);return t.concat(...e)},[])},debounceMethod:function(t,e,i){i=i||100;let n=t.prototype[e],o=e+"Timeout";t.prototype[e]=function(){clearTimeout(this[o]);let t=arguments;this[o]=setTimeout(()=>{n.apply(this,t),delete this[o]},i)}},docReady:function(t){var e=document.readyState;"complete"==e||"interactive"==e?setTimeout(t):document.addEventListener("DOMContentLoaded",t)},toDashed:function(t){return t.replace(/(.)([A-Z])/g,function(t,e,i){return e+"-"+i}).toLowerCase()}},a=e.console;return n.htmlInit=function(r,l){n.docReady(function(){let o="data-"+n.toDashed(l),t=document.querySelectorAll(`[${o}]`),s=e.jQuery;[...t].forEach(e=>{let t,i=e.getAttribute(o);try{t=i&&JSON.parse(i)}catch(t){return void(a&&a.error(`Error parsing ${o} on ${e.className}: `+t))}var n=new r(e,t);s&&s.data(e,l,n)})})},n})(t),(t=window).InfiniteScroll=((e,t,o)=>{let s=e.jQuery,r={};function l(t,e){var i=o.getQueryElement(t),n;if(i){if((t=i).infiniteScrollGUID)return(n=r[t.infiniteScrollGUID]).option(e),n;this.element=t,this.options=((t,e)=>{for(var i in e=e||{})u.call(e,i)&&f(t,i,e[i]);if(d)for(var i of d(e))p.call(e,i)&&f(t,i,e[i]);return t})({},l.defaults),this.option(e),s&&(this.$element=s(this.element)),this.create()}else console.error("Bad element for InfiniteScroll: "+(i||t))}l.defaults={},l.create={},l.destroy={};var i=l.prototype;Object.assign(i,t.prototype);let n=0,a=(i.create=function(){var t=this.guid=++n;if(this.element.infiniteScrollGUID=t,(r[t]=this).pageIndex=1,this.loadCount=0,this.updateGetPath(),this.getPath&&this.getPath())for(var e in this.updateGetAbsolutePath(),this.log("initialized",[this.element.className]),this.callOnInit(),l.create)l.create[e].call(this);else console.error("Disabling InfiniteScroll")},i.option=function(t){Object.assign(this.options,t)},i.callOnInit=function(){var t=this.options.onInit;t&&t.call(this,this)},i.dispatchEvent=function(e,i,n){this.log(e,n);var o=i?[i].concat(n):n,o;if(this.emitEvent(e,o),s&&this.$element){let t=e+=".infiniteScroll";i&&((o=s.Event(i)).type=e,t=o),this.$element.trigger(t,n)}},{initialized:t=>"on "+t,request:t=>"URL: "+t,load:(t,e)=>`${t.title||""}. URL: `+e,error:(t,e)=>t+". URL: "+e,append:(t,e,i)=>i.length+" items. URL: "+e,last:(t,e)=>"URL: "+e,history:(t,e)=>"URL: "+e,pageIndex:function(t,e){return`current page determined to be: ${t} from `+e}}),h=(i.log=function(i,n){if(this.options.debug){let t="[InfiniteScroll] "+i,e=a[i];e&&(t+=". "+e.apply(this,n)),console.log(t)}},i.updateMeasurements=function(){this.windowHeight=e.innerHeight;var t=this.element.getBoundingClientRect();this.top=t.top+e.scrollY},i.updateScroller=function(){var t=this.options.elementScroll;if(t){if(this.scroller=!0===t?this.element:o.getQueryElement(t),!this.scroller)throw new Error("Unable to find elementScroll: "+t)}else this.scroller=e},i.updateGetPath=function(){var t=this.options.path,e;t?"function"!=(e=typeof t)?"string"==e&&t.match("{{#}}")?this.updateGetPathTemplate(t):this.updateGetPathSelector(t):this.getPath=t:console.error("InfiniteScroll path option required. Set as: "+t)},i.updateGetPathTemplate=function(e){this.getPath=()=>{var t=this.pageIndex+1;return e.replace("{{#}}",t)};var t=e.replace(/(\\\?|\?)/,"\\?").replace("{{#}}","(\\d\\d?\\d?)"),t=new RegExp(t),t=location.href.match(t);t&&(this.pageIndex=parseInt(t[1],10),this.log("pageIndex",[this.pageIndex,"template string"]))},[/^(.*?\/?page\/?)(\d\d?\d?)(.*?$)/,/^(.*?\/?\?page=)(\d\d?\d?)(.*?$)/,/(.*?)(\d\d?\d?)(?!.*\d)(.*?$)/]),c=l.getPathParts=function(t){if(t)for(var e of h){var e=t.match(e),e,i,n;if(e)return[,e,i,n]=e,{begin:e,index:i,end:n}}};i.updateGetPathSelector=function(t){var e=document.querySelector(t);if(e){var e=e.getAttribute("href"),n=c(e);if(n){let{begin:t,index:e,end:i}=n;this.isPathSelector=!0,this.getPath=()=>t+(this.pageIndex+1)+i,this.pageIndex=parseInt(e,10)-1,this.log("pageIndex",[this.pageIndex,"next link"])}else console.error("InfiniteScroll unable to parse next link href: "+e)}else console.error("Bad InfiniteScroll path option. Next link not found: "+t)},i.updateGetAbsolutePath=function(){var o=this.getPath();if(o.match(/^http/)||o.match(/^\//))this.getAbsolutePath=this.getPath;else{let{pathname:t}=location,e=o.match(/^\?/),i=t.substring(0,t.lastIndexOf("/")),n=e?t:i+"/";this.getAbsolutePath=()=>n+this.getPath()}},l.create.hideNav=function(){var t=o.getQueryElement(this.options.hideNav);t&&(t.style.display="none",this.nav=t)},l.destroy.hideNav=function(){this.nav&&(this.nav.style.display="")},i.destroy=function(){for(var t in this.allOff(),l.destroy)l.destroy[t].call(this);delete this.element.infiniteScrollGUID,delete r[this.guid],s&&this.$element&&s.removeData(this.element,"infiniteScroll")},l.throttle=function(n,o){let s,r;return o=o||200,function(){let t=+new Date,e=arguments,i=()=>{s=t,n.apply(this,e)};s&&t{var t;return e.ok?e[i]().then(t=>("text"==i&&n&&(t=s.parseFromString(t,"text/html")),204==e.status?(this.lastPageReached(t,o),{body:t,response:e}):this.onPageLoad(t,o,e))):(t=new Error(e.statusText),this.onPageError(t,o,e),{response:e})}).catch(t=>{this.onPageError(t,o)});return this.dispatchEvent("request",null,[o,e]),e}},t.onPageLoad=function(t,e,i){return this.options.append||(this.isLoading=!1),this.pageIndex++,this.loadCount++,this.dispatchEvent("load",null,[t,e,i]),this.appendNextPage(t,e,i)},t.appendNextPage=function(t,e,i){var{append:n,responseBody:o,domParseResponse:s}=this.options;if("text"!=o||!s||!n)return{body:t,response:i};let r=t.querySelectorAll(n),l={body:t,response:i,items:r};if(!r||!r.length)return this.lastPageReached(t,e),l;let a=v(r),h=()=>(this.appendItems(r,a),this.isLoading=!1,this.dispatchEvent("append",null,[t,e,r,i]),l);return this.options.outlayer?this.appendOutlayerItems(a,h):h()},t.appendItems=function(t,e){t&&t.length&&(E(e=e||v(t)),this.element.appendChild(e))},t.appendOutlayerItems=function(t,i){let n=y.imagesLoaded||m.imagesLoaded;return n?new Promise(function(e){n(t,function(){var t=i();e(t)})}):(console.error("[InfiniteScroll] imagesLoaded required for outlayer option"),void(this.isLoading=!1))},t.onAppendOutlayer=function(t,e,i){this.options.outlayer.appended(i)},t.checkLastPage=function(t,e){let i,{checkLastPage:n,path:o}=this.options;n&&("function"!=typeof o||this.getPath()?("string"==typeof n?i=n:this.isPathSelector&&(i=o),i&&t.querySelector&&(t.querySelector(i)||this.lastPageReached(t,e))):this.lastPageReached(t,e))},t.lastPageReached=function(t,e){this.canLoad=!1,this.dispatchEvent("last",null,[t,e])},t.onPageError=function(t,e,i){return this.isLoading=!1,this.canLoad=!1,this.dispatchEvent("error",null,[t,e,i]),t},y.create.prefill=function(){var t;this.options.prefill&&((t=this.options.append)?(this.updateMeasurements(),this.updateScroller(),this.isPrefilling=!0,this.on("append",this.prefill),this.once("error",this.stopPrefill),this.once("last",this.stopPrefill),this.prefill()):console.error("append option required for prefill. Set as :"+t))},t.prefill=function(){var t=this.getPrefillDistance();this.isPrefilling=0<=t,this.isPrefilling?(this.log("prefill"),this.loadNextPage()):this.stopPrefill()},t.getPrefillDistance=function(){return this.options.elementScroll?this.scroller.clientHeight-this.scroller.scrollHeight:this.windowHeight-this.element.clientHeight},t.stopPrefill=function(){this.log("stopPrefill"),this.off("append",this.prefill)}}t=window,r=(g=t).InfiniteScroll,t=t.fizzyUIUtils,h=r.prototype,Object.assign(r.defaults,{scrollThreshold:400}),r.create.scrollWatch=function(){this.pageScrollHandler=this.onPageScroll.bind(this),this.resizeHandler=this.onResize.bind(this);var t=this.options.scrollThreshold;!t&&0!==t||this.enableScrollWatch()},r.destroy.scrollWatch=function(){this.disableScrollWatch()},h.enableScrollWatch=function(){this.isScrollWatching||(this.isScrollWatching=!0,this.updateMeasurements(),this.updateScroller(),this.on("last",this.disableScrollWatch),this.bindScrollWatchEvents(!0))},h.disableScrollWatch=function(){this.isScrollWatching&&(this.bindScrollWatchEvents(!1),delete this.isScrollWatching)},h.bindScrollWatchEvents=function(t){var t=t?"addEventListener":"removeEventListener";this.scroller[t]("scroll",this.pageScrollHandler),g[t]("resize",this.resizeHandler)},h.onPageScroll=r.throttle(function(){this.getBottomDistance()<=this.options.scrollThreshold&&this.dispatchEvent("scrollThreshold")}),h.getBottomDistance=function(){let t,e;return e=this.options.elementScroll?(t=this.scroller.scrollHeight,this.scroller.scrollTop+this.scroller.clientHeight):(t=this.top+this.element.clientHeight,g.scrollY+this.windowHeight),t-e},h.onResize=function(){this.updateMeasurements()},t.debounceMethod(r,"onResize",150);var h=window;{var S=h,t=h.InfiniteScroll,h=h.fizzyUIUtils,r=t.prototype;Object.assign(t.defaults,{history:"replace"});let n=document.createElement("a");t.create.history=function(){this.options.history&&(n.href=this.getAbsolutePath(),(n.origin||n.protocol+"//"+n.host)==location.origin?this.options.append?this.createHistoryAppend():this.createHistoryPageLoad():console.error(`[InfiniteScroll] cannot set history with different origin: ${n.origin} on ${location.origin} . History behavior disabled.`))},r.createHistoryAppend=function(){this.updateMeasurements(),this.updateScroller(),this.scrollPages=[{top:0,path:location.href,title:document.title}],this.scrollPage=this.scrollPages[0],this.scrollHistoryHandler=this.onScrollHistory.bind(this),this.unloadHandler=this.onUnload.bind(this),this.scroller.addEventListener("scroll",this.scrollHistoryHandler),this.on("append",this.onAppendHistory),this.bindHistoryAppendEvents(!0)},r.bindHistoryAppendEvents=function(t){var t=t?"addEventListener":"removeEventListener";this.scroller[t]("scroll",this.scrollHistoryHandler),S[t]("unload",this.unloadHandler)},r.createHistoryPageLoad=function(){this.on("load",this.onPageLoadHistory)},t.destroy.history=r.destroyHistory=function(){this.options.history&&this.options.append&&this.bindHistoryAppendEvents(!1)},r.onAppendHistory=function(t,e,i){var i,i;i&&i.length&&(i=i[0],i=this.getElementScrollY(i),n.href=e,this.scrollPages.push({top:i,path:n.href,title:t.title}))},r.getElementScrollY=function(t){return this.options.elementScroll?t.offsetTop-this.top:t.getBoundingClientRect().top+S.scrollY},r.onScrollHistory=function(){var t=this.getClosestScrollPage();t!=this.scrollPage&&(this.scrollPage=t,this.setHistory(t.title,t.path))},h.debounceMethod(t,"onScrollHistory",150),r.getClosestScrollPage=function(){let t,e;t=this.options.elementScroll?this.scroller.scrollTop+this.scroller.clientHeight/2:S.scrollY+this.windowHeight/2;for(var i of this.scrollPages){if(i.top>=t)break;e=i}return e},r.setHistory=function(t,e){var i=this.options.history;i&&history[i+"State"]&&(history[i+"State"](null,t,e),this.options.historyTitle&&(document.title=t),this.dispatchEvent("history",null,[t,e]))},r.onUnload=function(){var t;0!==this.scrollPage.top&&(t=S.scrollY-this.scrollPage.top+this.top,this.destroyHistory(),scrollTo(0,t))},r.onPageLoadHistory=function(t,e){this.setHistory(t.title,e)}}var h=window;{var b=0,t=h.InfiniteScroll,P=h.fizzyUIUtils;class j{constructor(t,e){this.element=t,this.infScroll=e,this.clickHandler=this.onClick.bind(this),this.element.addEventListener("click",this.clickHandler),e.on("request",this.disable.bind(this)),e.on("load",this.enable.bind(this)),e.on("error",this.hide.bind(this)),e.on("last",this.hide.bind(this))}onClick(t){t.preventDefault(),this.infScroll.loadNextPage()}enable(){this.element.removeAttribute("disabled")}disable(){this.element.disabled="disabled"}hide(){this.element.style.display="none"}destroy(){this.element.removeEventListener("click",this.clickHandler)}}t.create.button=function(){var t=P.getQueryElement(this.options.button);t&&(this.button=new j(t,this))},t.destroy.button=function(){this.button&&this.button.destroy()},t.Button=j}function I(t,e){for(var i in e)t[i]=e[i];return t}function w(t){return Array.isArray(t)?t:"object"==typeof t&&"number"==typeof t.length?i.call(t):[t]}function L(t,e,i){if(!(this instanceof L))return new L(t,e,i);var n=t;(n="string"==typeof t?document.querySelectorAll(t):n)?(this.elements=w(n),this.options=I({},this.options),"function"==typeof e?i=e:I(this.options,e),i&&this.on("always",i),this.getImages(),o&&(this.jqDeferred=new o.Deferred),setTimeout(this.check.bind(this))):s.error("Bad element for imagesLoaded "+(n||t))}function H(t){this.img=t}function A(t,e){this.url=t,this.element=e,this.img=new Image}function k(t){q(t,"none")}function x(t){q(t,"block")}function q(t,e){t&&(t.style.display=e)}function O(){}r=window,a=0,h=r.InfiniteScroll,c=r.fizzyUIUtils,r=h.prototype,h.create.status=function(){var t=c.getQueryElement(this.options.status);t&&(this.statusElement=t,this.statusEventElements={request:t.querySelector(".infinite-scroll-request"),error:t.querySelector(".infinite-scroll-error"),last:t.querySelector(".infinite-scroll-last")},this.on("request",this.showRequestStatus),this.on("error",this.showErrorStatus),this.on("last",this.showLastStatus),this.bindHideStatus("on"))},r.bindHideStatus=function(t){var e=this.options.append?"append":"load";this[t](e,this.hideAllStatus)},r.showRequestStatus=function(){this.showStatus("request")},r.showErrorStatus=function(){this.showStatus("error")},r.showLastStatus=function(){this.showStatus("last"),this.bindHideStatus("off")},r.showStatus=function(t){x(this.statusElement),this.hideStatusEventElements(),x(this.statusEventElements[t])},r.hideAllStatus=function(){k(this.statusElement),this.hideStatusEventElements()},r.hideStatusEventElements=function(){for(var t in this.statusEventElements)k(this.statusEventElements[t])},(t="undefined"!=typeof window?window:void 0).imagesLoaded=(t=(e=t).EvEmitter,o=e.jQuery,s=e.console,i=Array.prototype.slice,(L.prototype=Object.create(t.prototype)).options={},L.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},L.prototype.addElementImages=function(t){"IMG"==t.nodeName&&this.addImage(t),!0===this.options.background&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&l[e]){for(var i=t.querySelectorAll("img"),n=0;n{{var x=jQuery;let i=(e,t)=>{var e=new RegExp("[?&]"+e.replace(/[\[\]]/g,"\\$&")+"(=([^&#]*)|&|#|$)").exec("&"+t);return e&&e[2]?decodeURIComponent(e[2].replace(/\+/g," ")):""},v=(e,a,l)=>{"undefined"!=typeof MutationObserver&&new MutationObserver((e,t)=>{a?e[0].addedNodes.length&&l():(e[0].addedNodes.length||e[0].removedNodes.length)&&l()}).observe(e,{childList:!0,subtree:!0})},g=(x(()=>{e()}),x(document).on(rlArgs.customEvents,()=>{e()}),(a,e)=>a.find(e).filter((e,t)=>x(t).closest(".rl-gallery-container")[0]===a[0])),c=new Map,p=()=>window.RLG&&window.RLG.getPurifier?window.RLG.getPurifier():null,a=s=>{let d=(e=s,t=window.rlInfiniteGalleries,!x.isPlainObject(t)||(a=g(e,".rl-pagination[data-rl_infinite]").toArray().map(e=>e.getAttribute("data-rl_infinite")).find(e=>/^[0-9a-f]{32}$/.test(e)),e=g(e,".rl-gallery")[0],!(a&&e&&Object.prototype.hasOwnProperty.call(t,a)))||(t=t[a],!x.isPlainObject(t))||"string"!=typeof t.url||![t.galleryId,t.page,t.total].every(e=>Number.isInteger(e))||(l=c.get(a))&&l!==e&&document.contains(l)||"http:"!==(l=new URL(t.url,location.href)).protocol&&"https:"!==l.protocol?null:{key:a,gallery:e,settings:t,url:l});var e,t,a,l;if(!d)return!1;if(!x.data(d.gallery,"infiniteScroll")){if(!p())return!1;c.set(d.key,d.gallery);let r=x(d.gallery),{galleryId:i,page:a,total:l}=d.settings,o=`.rl-gallery-container[data-gallery_id="${i}"]`,n=o+" .rl-gallery-item",t=!0===d.settings.manually,e=g(s,".rl-load-more");e.css("display",""),r.infiniteScroll({path(){var e=a+this.loadCount+1,t;if(!(e>l))return(t=new URL(d.url)).searchParams.set("rl_page",e),t.href},append:n,status:!1,hideNav:g(s,".rl-pagination-bottom")[0],prefill:!t,loadOnScroll:!0,scrollThreshold:!t&&400,button:!!t&&e[0],debug:!1,history:!1,responseBody:"text",onInit(){let e=()=>{this.nav&&(this.nav.style.display="")};t&&s.removeClass("rl-loading"),this.on("request",()=>{s.addClass("rl-loading")}),this.on("load",t=>{{var a=t,l=o;let e=p();a.querySelectorAll("script").forEach(e=>e.remove()),a.querySelectorAll(l).forEach(t=>{try{e.sanitize(t,{IN_PLACE:!0,FORBID_TAGS:["form","fieldset","input","textarea","select","option","optgroup","datalist"],ADD_ATTR:["fetchpriority","itemprop","itemscope","itemtype","target"]})}catch(e){t.remove()}})}t.querySelector(n)||e()}),this.on("last",()=>{s.removeClass("rl-loading")}),this.on("error",()=>{s.removeClass("rl-loading"),e()}),this.on("append",(e,t,a,l)=>{s.removeClass("rl-loading"),x.event.trigger({type:"doResponsiveLightbox",script:rlArgs.script,selector:rlArgs.selector,args:rlArgs,pagination_type:"infinite",gallery_id:i,masonry:r.hasClass("rl-masonry-gallery")||r.hasClass("rl-basicmasonry-gallery"),delayLightbox:r.hasClass("rl-expander-gallery"),infinite:{gallery:r,body:e,items:a,response:l}})})}})}return!0},e=()=>{x(".rl-gallery-container").each((e,t)=>{var t=x(t);if(t.hasClass("rl-pagination-infinite")){try{if(a(t))return}catch(e){window.console.error(e)}g(t,".rl-load-more").css("display","none")}t.removeClass("rl-loading")}),x.event.trigger({type:"doResponsiveLightbox",script:rlArgs.script,selector:rlArgs.selector,args:rlArgs})},w=(x(document).on("click",".rl-pagination a.page-numbers",e=>{let l=x(e.currentTarget),r=l.closest(".rl-gallery-container");if(r.hasClass("rl-pagination-ajax")){e.preventDefault(),e.stopPropagation();let t=r.data("gallery_id"),a=r.find(".rl-gallery").data("gallery_no");return r.addClass("rl-loading"),x.post(rlArgs.ajaxurl,{action:"rl-get-gallery-page-content",gallery_id:t,gallery_no:a,post_id:rlArgs.postId,page:i("rl_page",l.prop("href")),nonce:rlArgs.nonce,preview:rlArgs.preview?"true":"false"}).done(e=>{r.replaceWith(x(e).removeClass("rl-loading")),x.event.trigger({type:"doResponsiveLightbox",script:rlArgs.script,selector:rlArgs.selector,args:rlArgs,pagination_type:"ajax",gallery_id:t,gallery_no:a})}).always(()=>{r.removeClass("rl-loading")}),!1}}),x(document).on("doResponsiveLightbox",e=>{if(void 0!==e.masonry&&!0===e.masonry)return!1;let l=e.script,t=e.selector;if(void 0===l||void 0===t)return!1;let r=e.args,a=!1;void 0!==e.delayLightbox&&!0===e.delayLightbox&&(a=!0),rl_view_image=(e,t)=>{x.event.trigger({type:"doLightboxViewImage",script:e,url:t})},rl_hide_image=(e,t)=>{x.event.trigger({type:"doLightboxHideImage",script:e,url:t})},setTimeout(()=>{let a=x(".flex-viewport");if(r.woocommerce_gallery){let t=x(".woocommerce-product-gallery");0===t.find(".woocommerce-product-gallery__trigger").length&&(t.prepend('🔍'),t.on("click",".woocommerce-product-gallery__trigger",e=>{if(e.preventDefault(),e.stopPropagation(),"lightgallery"===l)if(a.length){let e=a.find(".flex-active-slide a[data-rel] img"),t=a.find(".flex-active-slide a[data-rel]").data("lg-id");e.trigger("click.lgcustom-item-"+t)}else{let e=t.find("a[data-rel]").first();e.find("img").trigger("click.lgcustom-item-"+e.data("lg-id"))}else if("fancybox_pro"===l)if(a.length){let e=a.find(".flex-active-slide").index(),t=a.find(".flex-active-slide a[data-rel]").data("fancybox");Fancybox.fromOpener(`[data-fancybox="${t}"]`,{startIndex:e})}else{let e=t.find("a[data-rel]").first();Fancybox.fromOpener(`[data-fancybox="${e.data("fancybox")}"]`,{startIndex:0})}else(a.length?a.find(".flex-active-slide a[data-rel]"):t.find("a[data-rel]").first()).trigger("click")}))}},10),a?setTimeout(()=>{o(e)},0):o(e)}),(e,t)=>{var e=e.attr("data-"+t);return"string"==typeof e?e:""}),y=e=>e.replace(/[^]/g,e=>"&#"+e.charCodeAt(0)+";"),b=(e,t,a)=>{"string"==typeof a?e.attr(t,a):e.removeAttr(t)},o=p=>{let h=p.script,f=p.selector,m=p.args;switch(h){case"swipebox":let t=x("#swipebox-overlay").find(".slide.current"),a="",e=!1,l=!1;x(`a[rel*="${f}"], a[data-rel*="${f}"]`).swipebox({useCSS:m.animation,useSVG:m.useSVG,hideCloseButtonOnMobile:m.hideCloseButtonOnMobile,removeBarsOnMobile:m.removeBarsOnMobile,hideBarsDelay:m.hideBars?parseInt(m.hideBarsDelay):0,videoMaxWidth:parseInt(m.videoMaxWidth),loopAtEnd:m.loopAtEnd,afterOpen:()=>{l=!1;var e=(t=x("#swipebox-overlay").find(".slide.current")).find("img").attr("src");void 0!==e?(a=e,rl_view_image(h,a)):a="",v(document.getElementById("swipebox-slider"),!1,()=>{var e;""===a&&(void 0!==(e=t.find("img").attr("src"))?(a=e,rl_view_image(h,a)):a="")})},nextSlide:()=>{var e=(t=x("#swipebox-overlay").find(".slide.current")).find("img").attr("src");void 0!==e?(a=e,rl_view_image(h,a)):a=""},prevSlide:()=>{var e=(t=x("#swipebox-overlay").find(".slide.current")).find("img").attr("src");void 0!==e?(a=e,rl_view_image(h,a)):a=""},afterClose:()=>{l=!0,e&&(rl_hide_image(h,a),e=!1)}}),x(window).on("resize",()=>{l||(e=!0)});break;case"prettyphoto":{let e=!1,t="",a=x(`a[rel*="${f}"], a[data-rel*="${f}"]`),o=[],l=(a.each((e,t)=>{var t=x(t),a=w(t,"rl_title"),l=w(t,"rl_caption"),r=t.find("img"),i=r.attr("alt"),i=""!==a&&(void 0===i||""===i);i&&r.attr("alt",a),o.push({element:t,image:r.first(),title:i?y(a):null,caption:y(l)})}),e=>{let l=o.map(({element:e,image:t})=>({title:e.attr("title"),alt:t.attr("alt")}));o.forEach(({element:e,image:t,title:a,caption:l})=>{e.attr("title",l),null!==a&&t.attr("alt",a)});try{return e()}finally{o.forEach(({element:e,image:t},a)=>{b(e,"title",l[a].title),t.length&&b(t,"alt",l[a].alt)})}}),r=(a.prettyPhoto({hook:"data-rel",animation_speed:m.animationSpeed,slideshow:!!m.slideshow&&parseInt(m.slideshowDelay),autoplay_slideshow:m.slideshowAutoplay,opacity:m.opacity,show_title:m.showTitle,allow_resize:m.allowResize,allow_expand:m.allowExpand,default_width:parseInt(m.width),default_height:parseInt(m.height),counter_separator_label:m.separator,theme:m.theme,horizontal_padding:parseInt(m.horizontalPadding),hideflash:m.hideFlash,wmode:m.wmode,autoplay:m.videoAutoplay,modal:m.modal,deeplinking:m.deeplinking,overlay_gallery:m.overlayGallery,keyboard_shortcuts:m.keyboardShortcuts,social_tools:m.social?``:"",ie6_fallback:!0,changepicturecallback:()=>{e?e=!1:(t=x("#pp_full_res").find("img").attr("src"),rl_view_image(h,t),m.allowExpand&&x("a.pp_expand").on("click",()=>{e=!0}))},callback:()=>{rl_hide_image(h,t)}}),x.prettyPhoto.initialize);a.off("click.prettyphoto").on("click.prettyphoto",function(e){return l(()=>r.call(this,e))});break}case"nivo":x.each(x(`a[rel*="${f}"], a[data-rel*="${f}"]`),(e,t)=>{var a=x(t),t,l;null===(l=(t=t).getAttribute("data-lightbox-hidpi"))||window.RLG&&window.RLG.isAllowedMediaUrl&&window.RLG.isAllowedMediaUrl(l)||t.removeAttribute("data-lightbox-hidpi");let r=a.attr("data-rel");var l=a.data("rl_content");void 0!==(r=void 0!==r&&0!=r?r:a.attr("rel"))&&!1!==r&&(r.startsWith(f+"-gallery-")||"gallery"===l||1{let t=x(e)[0].find(".nivo-lightbox-content");r||(r=!0,v(document.getElementsByClassName("nivo-lightbox-content")[0],!0,()=>{i&&(o=t.find(".nivo-lightbox-image img").attr("src"),rl_view_image(h,o),i=!1)}))},afterHideLightbox:()=>{i=!0,rl_hide_image(h,o)},onPrev:e=>{i=!1,o=e[0].attr("href"),rl_view_image(h,o)},onNext:e=>{i=!1,o=e[0].attr("href"),rl_view_image(h,o)}});break;case"imagelightbox":let n=[],s="";x(`a[rel*="${f}"], a[data-rel*="${f}"]`).each((e,t)=>{var a=x(t).attr("data-rel");(void 0!==a&&!1!==a&&"norl"!==a||void 0!==(a=x(t).attr("rel"))&&!1!==a&&"norl"!==a)&&n.push(a)}),0{void 0!==p.pagination_type&&x(`a[data-rel="${t}"], a[rel="${t}"]`).each((e,t)=>{x(t).off("click.imageLightbox")}),x(`a[data-rel="${t}"], a[rel="${t}"]`).imageLightbox({animationSpeed:parseInt(m.animationSpeed),preloadNext:m.preloadNext,enableKeyboard:m.enableKeyboard,quitOnEnd:m.quitOnEnd,quitOnImgClick:m.quitOnImageClick,quitOnDocClick:m.quitOnDocumentClick,onLoadEnd:()=>{s=x("#imagelightbox").attr("src"),rl_view_image(h,s)},onEnd:()=>{rl_hide_image(h,s)}})}));break;case"tosrus":let d=[],g="",c=["jpg","jpe","jpeg","gif","png","webp","avif"];x(`a[rel*="${f}"], a[data-rel*="${f}"]`).each((e,t)=>{var a=x(t).attr("data-rel");(void 0!==a&&!1!==a&&"norl"!==a||void 0!==(a=x(t).attr("rel"))&&!1!==a&&"norl"!==a)&&d.push(a)}),0{void 0!==p.pagination_type&&(x("body").find(".tosrus-"+t).remove(),x(`a[data-rel="${t}"], a[rel="${t}"]`).each((e,t)=>{x(t).off("click.tos")}));var t=x(`a[data-rel="${t}"], a[rel="${t}"]`).tosrus({drag:!0,infinite:m.infinite,media:{image:{filterAnchors:function(e){var e=e.attr("href"),e;return"string"==typeof e&&(e=e.toLowerCase().split(/[?#]/)[0].split(".").pop(),-1{g=x(x(e.target).find(".tos-slider .tos-slide")[t]).find("img").attr("src"),rl_view_image(h,g)}),t.on("closing.tos",()=>{rl_hide_image(h,g)})}));break;case"featherlight":{let e=/\.(png|jpg|jpeg|gif|tiff?|bmp|svg|webp|avif)(?:[?#].*)?$/i;delete x.featherlight.contentFilters.jquery,x.extend(x.featherlight.contentFilters,{html:{regex:/[^]/,process:e=>x("
",{text:e})}}),x.featherlight.contentFilters.image.regex=e,x.featherlight.contentFilters.ajax.process=function(e){var t=x("
");return x.get(e).done(function(e){t.html(window.RLG&&window.RLG.sanitizeHtml?window.RLG.sanitizeHtml(e):"")}).fail(function(){t.text("No content found.")}).promise(t)},x.featherlight.contentFilters.iframe.process=function(e){var t,t,e;return window.RLG&&window.RLG.isAllowedEmbedUrl&&!window.RLG.isAllowedEmbedUrl(e)?(t=x("
")).text("Iframe not allowed."):(t=x("
"),(e=x("