cdn.fuseplatform.net Open in urlscan Pro
2a02:26f0:3400::1702:d58  Public Scan

URL: https://cdn.fuseplatform.net/publift/tags/2/2412/fuse.js
Submission: On November 07 via manual from RO — Scanned from DE

Form analysis 0 forms found in the DOM

Text Content

!function(t){"function"==typeof fuseDefine&&fuseDefine.amd?fuseDefine(t):t()}(function(){"use strict";var B=this,M=(Array.prototype.forEach||(Array.prototype.forEach=function(t,e){for(var n=e||window,i=0;i<B.length;i++)t.call(n,B[i],i,B)}),Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(t,e){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),i=n.length>>>0;if(0!=i)for(var o,r,e=0|e,s=Math.max(0<=e?e:i-Math.abs(e),0);s<i;){if((o=n[s])===(r=t)||"number"==typeof o&&"number"==typeof r&&isNaN(o)&&isNaN(r))return!0;s++}return!1}}),Array.prototype.find||(Array.prototype.find=function(t){if(null===this)throw new TypeError("Array.prototype.find called on null or undefined");if("function"!=typeof t)throw new TypeError("callback must be a function");for(var e=Object(this),n=e.length>>>0,i=arguments[1],o=0;o<n;o++){var r=e[o];if(t.call(i,r,o,e))return r}}),"undefined"!=typeof window&&window.NodeList&&!window.NodeList.prototype.forEach&&(NodeList.prototype.forEach=Array.prototype.forEach),this&&this.__spreadArray||function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o<r;o++)!i&&o in e||((i=i||Array.prototype.slice.call(e,0,o))[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))}),U=["verbose","debug","info","warn","error","off"],F=(G.prototype.setFuseDob=function(t){this.fuseDob=t},G.prototype.getTimestamp=function(){return this.fuseDob?" [".concat(Date.now()-this.fuseDob,"]"):""},G.prototype.callLogMethod=function(t){for(var e,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];"off"!==t&&(e=M(["[".concat(this.logName,"]-").concat(n[0]).concat(this.getTimestamp())],n.slice(1),!0),"warn"!==t&&"error"!==t||(1e3<=this.logs.length&&(this.logs=[]),this.logs.push({level:t,params:e})),"error"!==t&&U.indexOf(t)<U.indexOf(this.logLevel)||this.console["verbose"!=t?t:"debug"].apply(null,e))},G.prototype.error=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.callLogMethod("error",t)},G.prototype.warn=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.callLogMethod("warn",t)},G.prototype.log=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.callLogMethod("info",t)},G.prototype.info=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.callLogMethod("info",t)},G.prototype.debug=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.callLogMethod("debug",t)},G.prototype.setLogLevel=function(t){this.logLevel=t},G.prototype.getLogLevel=function(){return this.logLevel},G.prototype.getLogs=function(){return this.logs},G);function G(t,e,n,i){void 0===i&&(i=i||"off"),this.console=t,this.logName=e,this.fuseDob=n,this.logLevel=i,this.logs=[]}function W(t){return(W="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function g(t){return null==t}function u(t){return!g(t)}function z(t){throw new Error("exhaustiveCheck(".concat(t,") should not have been called"))}function j(t){if(!(t instanceof Error))throw t}function q(){this.sessionId=function(t){void 0===t&&(t=20);for(var e="",n=0;n<t;++n)e+=Math.floor(16*Math.random()).toString(16);return e}()}q.prototype.isInDebugMode=function(){return"true"===this.getQueryParam("fuse_debug")[1]},q.prototype.getWindowLocation=function(){if(!this.location)try{this.location=this.getBrowserWindowObject().self.location}catch(t){this.location=this.getBrowserWindowObject().location}return this.location},q.prototype.getFuseDob=function(){return this.getBrowserWindowObject().performance.timing.navigationStart},q.prototype.getPackageMajorVersion=function(){return 2},q.prototype.getBrowserWindowObject=function(){return window.self},q.prototype.getQueryParam=function(e){return this.getWindowLocation().search.split(/[?&]/).filter(function(t){return""!==t}).map(function(t){return t.split("=")}).filter(function(t){return t[0]===e})[0]||[]},q.prototype.getMainLogPrefix=function(){return"FUSE"},q.prototype.getLogLevel=function(){return this.isInDebugMode()||u(this.fuseDebugger)?"debug":this.getQueryParam("fuse_log_level")&&this.getQueryParam("fuse_log_level")[1]?(t=this.getQueryParam("fuse_log_level")[1],-1!==U.indexOf(t)?t:"off"):"off";var t},q.prototype.getLogger=function(){return this.logger||(this.logger=new F(this.getBrowserWindowObject().console,this.getMainLogPrefix(),this.getFuseDob(),this.getLogLevel())),this.logger},q.prototype.getFuseDebugger=function(){var t;return void 0===this.fuseDebugger&&(t=p.getBrowserWindowObject().fuseDebugger,this.fuseDebugger=null!=t?t:null,this.fuseDebugger&&(this.fuseDebugger.connect(),this.getLogger().debug("[MONITORING]: Debugger attached"))),null!=(t=this.fuseDebugger)?t:void 0},q.prototype.getSessionId=function(){return this.sessionId};var p=new q;function V(t,e){t&&e()}function H(t,e,n,i){t&&0<t?(n.info("[DELAY]: Delaying by ".concat(t,"ms to ").concat(e)),setTimeout(i,t)):i()}function Z(t){return p.getQueryParam(t)[1]||""}var Q={isEdgeBrowser:function(t){return/[E]dge/.test(t.navigator.userAgent)}},J=p.getLogger(),Y=function(){return tt("fuseDelayQuantcastInit")},K=function(){return tt("fuseDelayGptInit")},X=function(){return tt("fuseDelayPrebidInit")},$=function(){return tt("fuseDelayUamInit")},tt=function(t){var e=p.getQueryParam(t)[1];if(e){var n=parseInt(e);if(Number.isInteger(n))return n;J.info("[SETTINGS]: Could not parse ".concat(t," with value ").concat(e," as a number"))}return null},et=function(t){var e=p.getQueryParam(t)[1];if(g(e))return null;var n=/^(false|true|1|0)$/i.test(e)?Boolean(/^(true|1)$/i.test(e)):null;return g(n)&&J.info("[SETTINGS] Could not parse ".concat(t," with value: ").concat(e," as a boolean")),n},nt=(Object.defineProperty(it.prototype,"field",{get:function(){var t;return null!=(t=this._field)?t:this._field=this.initialiser()},enumerable:!1,configurable:!0}),it);function it(t){this.initialiser=t,this._field=null}function ot(t){return function(){return new nt(t).field}}var rt={fuse_blocked_url:[],fuse_breakpoints:{m:960,s:600,xs:0},fuse_cdn:"//cdn.fuseplatform.net/publift/tags/",fuse_id:2412,fuse_industry:["IAB19"],fuse_settings:{adblock:!1,amazonUam:{enabled:!0,pubID:"8b48e249-e9e6-4a52-8b48-396ea93403e8"},blockthrough:!1,cmp:!0,confiant:!1,disableAutoLoadSlots:!1,disableGdprPersonalisation:!1,disable_quantcast:!1,enableMiniScrollers:!1,fuse_test_urls:[],headerbidding:1e3,id5:{enabled:!1},identity:{enabled:!1},inskinWidth:1200,onLoadCallback:"",prebid:{analytics:[],breakpoint_options:{m:{enabled:!0,timeout:1e3},s:{enabled:!0,timeout:1e3},xs:{enabled:!0,timeout:1e3}},defaultTimeout:1e3,enabled:!0,sendAllBids:!1},quickstart:!1,responsive:!0,strict_cmp:!1,useDomObserver:!1,yandex:!1,yandexBlockId:""},fuse_slots:[{activateConditionConfig:{type:"none"},attributes:{adblock:!1,headerbidding:!1,interstitial:!1,refresh:25},bids:[{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"728x90"}},{bidder:"amx",labelAny:["m"],params:{size:"728x90",tagId:"cHVibGlmdC5jb20"}},{bidder:"appnexus",params:{placementId:"21616411"}},{bidder:"criteo",labelAny:["m"],params:{publisherSubId:"22410028857_1486324_728x90",size:"728x90",zoneId:1486324}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[728,90]}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/desk_footer_sticky@728x90",publisherId:"156762"}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/desk_footer_sticky@970x90",publisherId:"156762"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"728x90"}}],id:"22410028857",sizeMapping:{l:[],m:[[728,90],[970,90]],s:[],xl:[],xs:[]},sizes:[[728,90],[970,90]],slot:"/71161633,32403490/DIGWEB_digweb/desk_footer_sticky"},{activateConditionConfig:{type:"none"},attributes:{adblock:!1,headerbidding:!1,refresh:25},bids:[{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"300x250"}},{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"300x300"}},{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"336x280"}},{bidder:"amx",labelAny:["m"],params:{size:"300x250",tagId:"cHVibGlmdC5jb20"}},{bidder:"amx",labelAny:["m"],params:{size:"300x300",tagId:"cHVibGlmdC5jb20"}},{bidder:"amx",labelAny:["m"],params:{size:"336x280",tagId:"cHVibGlmdC5jb20"}},{bidder:"appnexus",params:{placementId:"21616412"}},{bidder:"criteo",labelAny:["m"],params:{publisherSubId:"22410054717_1486321_300x250",size:"300x250",zoneId:1486321}},{bidder:"criteo",labelAny:["m"],params:{publisherSubId:"22410054717_1486323_336x280",size:"336x280",zoneId:1486323}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[300,250]}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[300,300]}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[336,280]}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/rhs_sidebar@300x250",publisherId:"156762"}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/rhs_sidebar@300x300",publisherId:"156762"}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/rhs_sidebar@336x280",publisherId:"156762"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"300x250"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"300x300"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"336x280"}}],id:"22410054717",sizeMapping:{m:[[300,250],[300,300],[336,280]],s:[],xs:[]},sizes:[[300,250],[300,300],[336,280]],slot:"/71161633,32403490/DIGWEB_digweb/rhs_sidebar"},{activateConditionConfig:{type:"none"},attributes:{adblock:!1,headerbidding:!1,refresh:25},bids:[{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"300x250"}},{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"300x300"}},{bidder:"33across",labelAny:["m"],params:{productId:"siab",siteId:"ddzbU4Z34r64kgaKlKyvbs",size:"336x280"}},{bidder:"amx",labelAny:["m"],params:{size:"300x250",tagId:"cHVibGlmdC5jb20"}},{bidder:"amx",labelAny:["m"],params:{size:"300x300",tagId:"cHVibGlmdC5jb20"}},{bidder:"amx",labelAny:["m"],params:{size:"336x280",tagId:"cHVibGlmdC5jb20"}},{bidder:"appnexus",params:{placementId:"21616468"}},{bidder:"criteo",labelAny:["m"],params:{publisherSubId:"22410207854_1486321_300x250",size:"300x250",zoneId:1486321}},{bidder:"criteo",labelAny:["m"],params:{publisherSubId:"22410207854_1486323_336x280",size:"336x280",zoneId:1486323}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[300,250]}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[300,300]}},{bidder:"ix",labelAny:["m"],params:{siteId:"675469",size:[336,280]}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/home_mrec_1@300x250",publisherId:"156762"}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/home_mrec_1@300x300",publisherId:"156762"}},{bidder:"pubmatic",labelAny:["m"],params:{adSlot:"71161633/DIGWEB_digweb/home_mrec_1@336x280",publisherId:"156762"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"300x250"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"300x300"}},{bidder:"triplelift",labelAny:["m"],params:{inventoryCode:"Digwebinterface_StandardDisplay",size:"336x280"}}],id:"22410207854",sizeMapping:{m:[[300,250],[300,300],[336,280]],s:[],xs:[]},sizes:[[300,250],[300,300],[336,280]],slot:"/71161633,32403490/DIGWEB_digweb/home_mrec_1"}],fuse_tenant:"publift",fuse_uuid:"72158275-e88b-51ae-abb5-325d2f07aa84",sco:{asi:"publift.com",sellerId:"01F5YDEWC1SFTZM95HG4KXN3PP"},supported_sizes:{l:[[300,250],[320,480],[336,280]],m:[[120,600],[160,600],[300,250],[300,300],[300,600],[320,480],[336,280],[728,90],[970,90]],s:[[300,250],[320,480],[336,280]],xl:[],xs:[[300,250],[320,480],[336,280]]},tenantId:"DGKSPXNV53",fuse_flavour:"default",publication_metadata:{publication_id:3,generation_version:"4.47200.0",generation_time:"2022-08-26T03:56:48.130Z",revision:"v4"},fuse_prebid_hash:"f9660b0904b2b08f623608aa1b601347"};function st(t){this.myWindow=t}st.prototype.isDevelopmentMode=function(){return 0==rt.publication_metadata.publication_id},st.prototype.getAccountSettings=function(){var t=this.myWindow.field;return this.isDevelopmentMode()&&t.fuseConfig?t.fuseConfig:rt},st.prototype.getBreakpoints=function(){var t={},e=this.getAccountSettings();return e.fuse_breakpoints.xl&&(t.xl=e.fuse_breakpoints.xl),e.fuse_breakpoints.l&&(t.l=e.fuse_breakpoints.l),t.m=e.fuse_breakpoints.m,t.s=e.fuse_breakpoints.s,t.xs=e.fuse_breakpoints.xs,t},st.prototype.isUseBrowserOuterwidth=function(){var t;return null!=(t=null!=(t=et("fuseUseBrowserOuterwidth"))?t:this.getAccountSettings().fuse_settings.isUseBrowserOuterwidth)&&t};var at=new st(new nt(function(){return p.getBrowserWindowObject()})),ct=(ut.prototype.subscribe=function(t){this.subscribers.push(t)},ut.prototype._unsubscribe=function(t){t=this.subscribers.indexOf(t);return 0<=t&&(this.subscribers.splice(t,1),!0)},ut.prototype.unsubscribe=function(t){var e=this.findWrapper(t);return e?this._unsubscribe(e):this._unsubscribe(t)},ut.prototype.findWrapper=function(e){var t;return null==(t=this.wrapped.filter(function(t){return t.subscriber===e}).shift())?void 0:t.wrapper},ut.prototype.once=function(e){function n(t){e(t),i.unsubscribe(n)}var i=this;this.subscribe(n),this.wrapped.push({wrapper:n,subscriber:e})},ut.prototype.immediateOrOnce=function(t){return u(this.lastEmitted)?(this.logger.debug("[EVENT][".concat(this.eventName,"]: Already triggered, invoking callback synchronously")),t(this.lastEmitted),!0):(this.once(t),!1)},ut.prototype.emit=function(e){var n=this,t=this.subscribers.length;0<t?this.logger.debug("[EVENT][".concat(this.eventName,"]: Fired, start processing ").concat(t," callbacks")):this.logger.debug("[EVENT][".concat(this.eventName,"]: Fired, no pending callbacks")),this.lastEmitted=e,this.subscribers.map(function(t){return t}).forEach(function(t){try{t(e)}catch(t){t instanceof Error?n.logger.error("[EVENT][".concat(n.eventName,"]: Caught exception in callback with item ").concat(e),t.message,t.stack):n.logger.error("[EVENT][".concat(n.eventName,"]: Caught exception of invalid type in callback with item ").concat(e))}})},ut.prototype.getSubscriberCount=function(){return this.subscribers.length},ut);function ut(t,e){this.logger=t,this.eventName=e,this.subscribers=[],this.lastEmitted=null,this.wrapped=[]}dt.prototype.subscribe=function(t){this.delegate.subscribe(t)},dt.prototype.unsubscribe=function(t){this.delegate.unsubscribe(t)},dt.prototype.once=function(t){this.delegate.once(t)},dt.prototype.immediateOrOnce=function(t){return this.delegate.immediateOrOnce(t)};var lt=dt;function dt(t,e,n,i){var o=this;this.logger=t,this.eventName=e,this.source=n,this.filter=i,this.delegate=new ct(t,e),n.subscribe(function(t){t=o.filter(t);u(t)&&o.delegate.emit(t)})}function t(t,e){void 0===e&&(e=function(){}),this.logger=t,this.addDebugProxy=e,this.emitters={},this.observables={}}Object.defineProperty(t.prototype,"onTagInitComplete",{get:function(){return this.getEmitter("onTagInitComplete")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pageInitObservable",{get:function(){return this.onPageInit},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onPageInit",{get:function(){return this.getEmitter("onPageInit")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onZoneEvent",{get:function(){return this.getEmitter("onZoneEvent")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onZoneRegistered",{get:function(){return this.getFiltered("register_zone",this.onZoneEvent,function(t){return"registered"==t.zoneEventType?t:null})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onZoneActivateApi",{get:function(){return this.getFiltered("activate_zone_api",this.onZoneEvent,function(t){return"activate_zone_api"==t.zoneEventType?t:null})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activateZoneCalledObservable",{get:function(){return this.onZoneActivateApi},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onComponentInitEvent",{get:function(){return this.getEmitter("onComponentInitEvent")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onInitManagerReady",{get:function(){return this.getEmitter("onInitManagerReady")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onWindowResized",{get:function(){return this.getEmitter("onWindowResized")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onBreakpointChanged",{get:function(){return this.getFiltered("onBreakpointChanged",this.onWindowResized,function(t){return t.crossedBp?t:null})},enumerable:!1,configurable:!0}),t.prototype.getEmitter=function(t){var e,n=new ct(this.logger(),t),i=this.addDebugProxy(),i=i?i(n):n;return null!=(e=(n=this.emitters)[t])?e:n[t]=i},t.prototype.getFiltered=function(t,e,n){var i,o;return null!=(i=(o=this.observables)[t])?i:o[t]=new lt(this.logger(),t,e,n)};var h=new t(ot(function(){return p.getLogger()}),ot(function(){var t;return null==(t=p.getFuseDebugger())?void 0:t.fuseEventEmitterWrapper()}));function gt(e,n,i){function o(){var t=Date.now()-c;t<e&&0<=t?r=setTimeout(o,e-t):(r=null,i||(u=n.apply(a,s),r||(a=s=null)))}var r,s,a,c,u;return function(){a=this,s=arguments,c=Date.now();var t=i&&!r;return r=r||setTimeout(o,e),t&&(u=n.apply(a,s),a=s=null),u}}ht.prototype.getCurrentBreakpoint=function(){return t=this.breakpoints,n=this.getViewportStatus().width,i=null,Object.entries(t).forEach(function(t){var e=t[0],t=t[1];t<=n&&(!i||t>i.size)&&(i={size:t,name:e})}),i;var t,n,i},ht.prototype.breakpointSupplier=function(){return this.getCurrentBreakpoint.bind(this)},ht.prototype.isNotXsBreakpoint=function(){return"xs"!==this.getCurrentBreakpoint().name},ht.prototype.getViewportStatus=function(){var t=this.browserWindow;return{width:this.options.isUseOuterwidth.field?t.outerWidth:t.innerWidth,innerHeight:t.innerHeight,outerHeight:t.outerHeight,hidden:t.document.hidden,offset:{x:t.scrollX,y:t.scrollY}}},ht.prototype.initBpWatch=function(){var i=this,o=this.getCurrentBreakpoint().size;this.browserWindow.addEventListener("resize",gt(500,function(){var t=i.getCurrentBreakpoint(),e=t.size,t=t.name,n=o!==e;return o=e,i.onWindowResized.emit({crossedBp:n,name:t,currentFrom:e})}))};var pt=ht;function ht(t,e,n,i,o){this.logger=t,this.browserWindow=e,this.breakpoints=n,this.onWindowResized=i,this.options=o,this.initBpWatch(),this.logger.debug("[VIEWPORT]: Initialised at breakpoint ".concat(this.getCurrentBreakpoint().name))}function ft(){}ft.prototype.getViewportInfo=function(){return this.viewportInfo||(this.viewportInfo=new pt(p.getLogger(),p.getBrowserWindowObject(),at.getBreakpoints(),h.onWindowResized,{isUseOuterwidth:new nt(function(){return at.isUseBrowserOuterwidth()})})),this.viewportInfo};var bt,mt,yt,l=new ft,St=p.getBrowserWindowObject(),vt=p.getLogger(),It=function(t,e){vt.debug("[INIT]: Downloading library ".concat(t.name));var n,i=St.document.createElement("script"),t=(i.async=!0,i.type="text/javascript","function"==typeof e&&(i.readyState?i.onreadystatechange=function(){"loaded"!==i.readyState&&"complete"!==i.readyState||(i.onreadystatechange=null,e())}:i.onload=function(){e()}),i.src="https:".concat(t.url).concat(t.file),St.document.getElementsByTagName("script")[0]);null!=(n=t.parentNode)&&n.insertBefore(i,t)},Et=((n=bt=bt||{}).Desktop="desktop",n.Tablet="tablet",n.Mobile="mobile",(n=mt=mt||{}).Chrome="chrome",n.Safari="safari",n.Opera="opera",n.Edge="edge",n.IE11="ie11",n.Firefox="firefox",n.Other="other",(n=yt=yt||{}).IOS="ios",n.MacOS="mac",n.Android="android",n.Windows="windows",n.Linux="linux",n.ChromeOs="chromeos",n.Other="other",[{regex:/chrome|crios|crmo/i,browser:mt.Chrome},{regex:/firefox|iceweasel|fxios/i,browser:mt.Firefox},{regex:/safari|applewebkit/i,browser:mt.Safari},{regex:/opera/i,browser:mt.Opera},{regex:/opr\/|opios/i,browser:mt.Opera},{regex:/\sedg\//i,browser:mt.Edge},{regex:/edg([ea]|ios)/i,browser:mt.Edge}]),wt=[{regex:/huawei/i,device:bt.Mobile},{regex:/nexus\s*(?:7|8|9|10).*/i,device:bt.Tablet},{regex:/ipad/i,device:bt.Tablet},{regex:/tablet(?! pc)/i,device:bt.Tablet},{regex:/(ipod|iphone)/i,device:bt.Mobile},{regex:/nexus\s*[0-6].*/i,device:bt.Mobile},{regex:/[^-]mobi/i,device:bt.Mobile}],Ct=[{os:yt.MacOS,regex:/macintosh/i},{os:yt.IOS,regex:/(ipod|iphone|ipad)/i},{os:yt.Android,regex:/android/i},{os:yt.Windows,regex:/windows /i},{os:yt.Linux,regex:/linux/i},{os:yt.ChromeOs,regex:/CrOS/}],Tt=(At.prototype.parseDevice=function(){var e=this,t=wt.filter(function(t){return t.regex.test(e.userAgent)});return 0<t.length?t[0].device:null!=(t=this.browserWindow.navigator.userAgentData)&&t.mobile?bt.Mobile:bt.Desktop},At.prototype.parseBrowser=function(){var e=this,t=Et.filter(function(t){return t.regex.test(e.userAgent)});return 0<t.length?t[0].browser:mt.Other},At.prototype.parseOperatingSystem=function(){var e=this,t=Ct.filter(function(t){return t.regex.test(e.userAgent)});return 0<t.length?t[0].os:yt.Other},At.prototype.getDevice=function(){return this.device},At.prototype.getBrowser=function(){return this.browser},At.prototype.getOperatingSystem=function(){return this.os},At);function At(t){this.browserWindow=t,this.userAgent=t.navigator.userAgent,this.device=this.parseDevice(),this.browser=this.parseBrowser(),this.os=this.parseOperatingSystem()}var _t=this&&this.__assign||function(){return(_t=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},Pt=(Rt.prototype.getSlotProblems=function(){return this.slotProblems},Rt.prototype.addSlotProblem=function(t){1e3<=this.slotProblems.length&&(this.slotProblems=this.slotProblems.slice(100)),this.slotProblems.push(_t(_t({},t),{time:this.getElapsedTime()}))},Rt.prototype.getFuseDob=function(){return this.fuseDob},Rt.prototype.getElapsedTime=function(){return(new Date).getTime()-this.getFuseDob()},Rt.prototype.reportFirstGptRequest=function(){this._firstGptRequestMs=this.getElapsedTime()},Object.defineProperty(Rt.prototype,"firstGptRequestMs",{get:function(){return this._firstGptRequestMs},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"tagLoadedMs",{get:function(){return this._tagLoadedMs},enumerable:!1,configurable:!0}),Rt.prototype.setStateStatus=function(t){var e,n=Date.now();this.states.push(((e={})[t]=!0,e.ts=n,e.load_time_ms=n-this.getFuseDob(),e))},Rt.prototype.addAdEvent=function(t,e){var n=Date.now();this.events.push({adEvent:t,requestID:e,ts:n,event_time_ms:n-this.getFuseDob()})},Rt);function Rt(t){this.fuseDob=t,this.states=[],this.events=[],this.slotProblems=[];var e,t=Date.now();this._tagLoadedMs=t-this.getFuseDob(),this.states.push(((e={}).tag_loaded=!0,e.ts=t,e.load_time_ms=this._tagLoadedMs,e))}function Dt(t){if(1e4<=t)return"over_9999";var e=t<4e3?500:1e3,t=Math.floor(t/e)*e;return"".concat(t,"-").concat(t+e-1)}function Ot(){return{_tag:"deferred"}}function kt(){return{_tag:"disabled"}}function xt(){return{_tag:"cancelled"}}function Lt(t,e){return{_tag:"loading",loadStart:t,deferredLoad:e=void 0===e?!1:e}}function Nt(t,e,n){return{_tag:"ready",loadStart:t.loadStart,loadFinish:e,loadElapsed:e-t.loadStart,deferredLoad:t.deferredLoad,output:n}}Object.defineProperty(Mt.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Mt.prototype.updateState=function(t,e){this._state[t]=e,this.reporter.setStateStatus("component_init_".concat(t,"_").concat(e._tag)),"ready"===e._tag&&this.logger.log("[INIT]: Component ".concat(t," is ready")),this.onComponentInitEvent.emit({component:t,state:e})};var Bt=Mt;function Mt(t,e,n){this.onComponentInitEvent=t,this.logger=e,this.reporter=n,this._state={yandex:{_tag:"pending"},gpt:{_tag:"pending"},prebid:{_tag:"pending"},cmp:{_tag:"pending"},uam:{_tag:"pending"},docReadyScan:{_tag:"pending"}}}function Ut(t){return"disabled"==t._tag||"ready"===t._tag&&t.output.allowPersonalisation}function Ft(t){return"ready"==t._tag?t.output.jurisdiction:"unknown"}var Gt=this&&this.__assign||function(){return(Gt=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},Wt=(e.prototype.recordSlotRequest=function(t){var e="slot-request",n=this.getCmpData(),n=this.makeUrl(e,{auid:t},n);this.logDetails(t,e),this.makeRequest(n)},e.prototype.recordFuseLoad=function(){var t=this.makeUrl("fuse-load");this.makeRequest(t)},e.prototype.makeUrl=function(t,e,n){var i=!["none","unknown"].includes(null==n?void 0:n.jurisdiction)&&null!=n&&n.personalisation?"consent":"noconsent",e=this.buildQueryParameters(Gt(Gt(Gt({},e),{cmpj:null==n?void 0:n.jurisdiction}),this.getCommonMetadata(t))),n="https:".concat(this.baseUrl);return"https://".concat(this.getHostName(n),"/telemetry/").concat(i).concat(e)},e.prototype.makeRequest=function(t){var e=new XMLHttpRequest;return e.open("GET",t,!0),e.send(),e},e.prototype.logDetails=function(t,e){this.logger.debug("[STATS]: Record ".concat(e," event for fuse ").concat(this.fuseId,", ad ").concat(t," on device ").concat(this.deviceInfo.getDevice()," and browser ").concat(this.deviceInfo.getBrowser()))},e.prototype.buildQueryParameters=function(t){return Object.entries(t).reduce(function(t,e){var n=e[0],e=e[1];return e?"".concat(t?t+"&":"?").concat(encodeURIComponent(n),"=").concat(encodeURIComponent(e)):t},"")},e.prototype.getCommonMetadata=function(t){var e=[this.browserWindow.location.href,this.getReferrer()],n=e[0],e=e[1];return{v:"1",ttm:Date.now(),cookie:this.browserWindow.navigator.cookieEnabled,res:"".concat(screen.width,"x").concat(screen.height),device:this.deviceInfo.getDevice(),browser:this.deviceInfo.getBrowser(),fuuid:this.fuseUuid,fid:this.fuseId,pubid:this.publicationId,url:this.purify(n),refr:this.purify(e),sid:this.sessionId,srate:100,adserver:this.adServer,etm:this.reporter.getElapsedTime(),e:t}},e.prototype.getCmpData=function(){var t=this.componentState.state.cmp;return{jurisdiction:Ft(t),personalisation:Ut(t)}},e.prototype.getHostName=function(t){var e=/^(?:(?:https?|ftp):)\/*(?:[^@]+@)?([^:/#]+)/.exec(t);return e?e[1]:t},e.prototype.getParameter=function(t,e){t=/^(?:https?|ftp)(?::\/*(?:[^?]+))([?][^#]+)/.exec(t);return t&&1<(null==t?void 0:t.length)?this.fromQuerystring(e,t[1]):null},e.prototype.fromQuerystring=function(t,e){t=new RegExp("^[^#]*[?&]"+t+"=([^&#]*)").exec(e);return t?decodeURIComponent(t[1].replace(/\+/g," ")):null},e.prototype.getReferrer=function(t){var e=this.fromQuerystring("referrer",this.browserWindow.location.href)||this.fromQuerystring("referer",this.browserWindow.location.href);if(e)return e;if(t)return t;try{if(this.browserWindow.top)return this.browserWindow.top.document.referrer;if(this.browserWindow.parent)return this.browserWindow.parent.document.referrer}catch(t){}return this.browserWindow.document.referrer},e.prototype.purify=function(t){return t.replace(/#.*/,"").replace(/[{}]/g,"")},e);function e(t,e,n,i,o,r,s){this.componentState=t,this.deviceInfo=e,this.logger=n,this.browserWindow=i,this.sessionId=o,this.reporter=r,this.baseUrl=s.getFuseCDN(),this.fuseUuid=s.getFuseUUID(),this.fuseId=s.getFuseId(),this.publicationId=s.getPublicationId(),this.adServer=s.isYandexEnabled()?"yandex":"gpt"}var zt=function(t,e,n,i,o){var r=t.top,s=t.bottom,a=t.left,c=t.right,u=t.width,t=t.height*o,u=u*o;return 0<=r+t+i&&0<=a+u&&s-t-i<=n&&c-u<=e};function jt(t,e,n,i){e=e.getBoundingClientRect(),e=zt(e,t.width,t.innerHeight,i,n/100);return!t.hidden&&e}Vt.prototype.destroy=function(){this.window.removeEventListener("scroll",this.triggeredCB,this.options)};var qt=Vt;function Vt(t){this.options={capture:!0,passive:!0},this.window=t.api.viewportInfo.browserWindow,this.triggeredCB=t.onTriggeredCB,this.window.addEventListener("scroll",this.triggeredCB,this.options)}var Ht="InView",Zt=(Qt.prototype.buildTriggers=function(t){return[new qt(t)]},Qt.prototype.check=function(t,e){var n,t=e.slotRegistry.getSlot(t);return!!t&&(n=e.viewportInfo.getCurrentBreakpoint().name,!(!g(n=this.params[n])&&!1!==n)||jt(e.viewportInfo.getViewportStatus(),t.zoneDiv,50,n))},Qt);function Qt(t){this.params=t,this.name=Ht}Jt.prototype.destroy=function(){this.unsubscribe()};var n=Jt;function Jt(e,t,n){function i(t){n(t)&&e.onTriggeredCB()}this.unsubscribe=function(){return t.unsubscribe(i)},t.subscribe(i)}(this&&this.__extends||(Yt=function(t,e){return(Yt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}Yt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}))($t,Kt=n);var Yt,Kt,Xt=$t;function $t(t){var e=t.api.slotRegistry.getSlot(t.id).zoneInstanceId,n=t.api.events.onZoneActivateApi;return Kt.call(this,t,n,function(t){return t.instanceId===e})||this}var te="ManualActivate",ee=(ne.prototype.buildTriggers=function(t){return[new Xt(t)]},ne.prototype.check=function(t,e){t=null==(t=e.slotRegistry.getSlot(t))?void 0:t.zoneInstanceId;return u(t)&&e.zoneRegistry.isManuallyActivated(t)},ne);function ne(){this.name=te}var i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},s=at.getAccountSettings(),ie=!1,o=s.fuse_settings,oe=p.getLogger();function r(t,e){var r=this;this.breakpoints=t,this.viewportInfo=e,this.fuseSettings=s.fuse_settings,this.cleaned_fuse_slots=!1,this.v2Compatibility={disableWidgetsRenderer:!1},this.isNotFluid=function(t){return Array.isArray(t)?"fluid"!==t[0]:"fluid"!==t},this.isUamEnabled=function(){return!r.isYandexEnabled()&&(o.amazonUam&&o.amazonUam.enabled)},this.isResponsiveEnabled=function(){return o.responsive},this.getInskinWidth=function(){return o.inskinWidth},this.removeFluidSizes=function(t){return t.filter(r.isNotFluid)},this.getCurrentSizeMapSizes=function(e,t){var n=(r.getFuseSlots().filter(function(t){return t.id===e})||[])[0];if(!n)return oe.warn("[SLOTS]: getCurrentSizeMapSizes(): Could not find fuseSlot with id ".concat(e)),[];var i=null==(i=n.sizeMapping)?void 0:i[t];return n.sizeMapping&&i?(0===(i=r.removeFluidSizes(i)).length&&oe.debug("[SLOTS]: No non-fluid sizes available for ".concat(e," at current breakpoint: '").concat(t,"'")),i):(oe.warn('[SLOTS]: Fuse slot "'.concat(e,'" has no sizemap at breakpoint ').concat(t,", sizeless prebid units may act strangely.")),r.removeFluidSizes(n.sizes||[]))},this.getSupportedSizes=function(t){return s.supported_sizes[t]},this.getCurrentBreakpoint=function(t){var n,i=r.breakpoints,o=null!=t?t:r.viewportInfo.getViewportStatus().width;return Object.keys(i).forEach(function(t){var e=i[t];e<=o&&(!n||e>n.size)&&(n={size:e,name:t})}),n}}r.prototype.getUamSettings=function(){return o.amazonUam},r.prototype.isPrebidEnabled=function(){return!this.isYandexEnabled()&&(!ie&&o.prebid&&o.prebid.enabled)},r.prototype.isPrebidServer=function(){return 0<this.getPrebidServerBidders().length&&!et("fuseDisablePrebidServer")},r.prototype.getPrebidServerBidders=function(){return this.fuseSettings.prebidServerBidderCodes||[]},r.prototype.getPrebidSettings=function(){return o.prebid},r.prototype.getFuseUUID=function(){return s.fuse_uuid},r.prototype.getSco=function(){return s.sco},r.prototype.getFuseId=function(){return s.fuse_id},r.prototype.getUseTelemetry=function(){return Boolean(o.useTelemetry)},r.prototype.getConfiantId=function(){return o.confiantId},r.prototype.getLowDwellPages=function(){return o.lowDwellPages||[]},r.prototype.getMaxViewportsFirstAuction=function(){return o.maxViewportsFirstAuction},r.prototype.isQuantcastEnabled=function(){return this.isCmpRequired()&&(g(o.disable_quantcast)||!o.disable_quantcast)},r.prototype.isCmpRequired=function(){return!this.isYandexEnabled()&&o.cmp},r.prototype.getCmpMode=function(){return this.isYandexEnabled()||!o.cmp?"disabled":o.strict_cmp?"strict":"enabled"},r.prototype.getGdprTimeoutMillis=function(){var t;return null!=(t=tt("fuseTagGdprTimeoutMs"))?t:2e4},r.prototype.getUspTimeoutMillis=function(){return 100},r.prototype.getTagStartCutoffMs=function(){var t;return null!=(t=tt("fuseTagStartCutoffMs"))?t:o.tagStartCutoffMs},r.prototype.getPrebidDownloadCutoffMs=function(){var t;return null!=(t=tt("fusePrebidDownloadCutoffMs"))?t:o.prebidDownloadCutoffMs},r.prototype.getPrebidTagStartCutoffMs=function(){var t;return null!=(t=tt("fusePrebidTagStartCutoffMs"))?t:o.prebidTagStartCutoffMs},r.prototype.getUamTagStartCutoffMs=function(){var t;return null!=(t=tt("fuseUamTagStartCutoffMs"))?t:o.uamTagStartCutoffMs},r.prototype.getAuctionMaxSlots=function(){var t;return null!=(t=null!=(t=tt("fuseAuctionMaxSlots"))?t:o.auctionMaxSlots)?t:99},r.prototype.isRefreshCountFromLoaded=function(){var t;return null!=(t=null!=(t=et("fuseRefreshTimerFromLoaded"))?t:o.refreshTimerFromLoaded)&&t},r.prototype.isIdentityEnabled=function(){var t;return null!=(t=null==(t=o.identity)?void 0:t.enabled)&&t},r.prototype.getIdentitySettings=function(){return o.identity},r.prototype.isId5Enabled=function(){var t;return null!=(t=null==(t=o.id5)?void 0:t.enabled)&&t},r.prototype.getId5Settings=function(){return o.id5},r.prototype.isConfiantEnabled=function(){return!this.isYandexEnabled()&&o.confiant},r.prototype.isBlockthroughEnabled=function(){return!this.isYandexEnabled()&&o.blockthrough},r.prototype.isWidgetRendererEnabled=function(){return!this.v2Compatibility.disableWidgetsRenderer&&!o.disableWidgetsRenderer},r.prototype.setDisableWidgetRenderer=function(){this.v2Compatibility.disableWidgetsRenderer=!0},r.prototype.isStrictCmp=function(){return Boolean(o.strict_cmp)},r.prototype.isRequestGdprPersonalisation=function(){return!o.disableGdprPersonalisation},r.prototype.setForceDisablePrebid=function(){oe.log("[CONFIG]: Forcefully disabling prebid"),ie=!0},r.prototype.isMiniScrollersEnabled=function(){return Boolean(this.fuseSettings.enableMiniScrollers)},r.prototype.getTopStickyHeaderSelector=function(){var t;return(null==(t=this.getFuseSlots().filter(function(t){var e;return(null==(e=t.attributes)?void 0:e.miniscroller)&&(null==(e=t.miniscrollerAttributes)?void 0:e.topStickyHeaderSelector)})[0])?void 0:t.miniscrollerAttributes.topStickyHeaderSelector)||Z("fuseTopStickyHeaderSelector")||o.topStickyHeaderSelector},r.prototype.getSlotRefWithoutMcm=function(t){var e=/^(\/\d*),(\d*)(\/.*)$/i;if(!1===e.test(t))return oe.debug("[SETTINGS]: regExGamAdUnitRef.test(slotRef): ".concat(JSON.stringify(e.test(t)),", slotRef: ").concat(t)),t;oe.debug("[SETTINGS]: regExGamAdUnitRef.test(slotRef): ".concat(JSON.stringify(e.test(t)),", slotRef: ").concat(t));e=e.exec(t);return oe.debug("[SETTINGS]: slotRef: ".concat(t,", matches: ").concat(JSON.stringify(e))),"".concat(e[1]).concat(e[3])},r.prototype.cleanSlotBasedOnMcmMode=function(t){var e=this.getSlotRefWithoutMcm(t.slot);return oe.debug("[SETTINGS]: before: with MCM: ".concat(t.slot,", after: without MCM: ").concat(e)),i(i({},t),{slot:e})},r.prototype.cleanSlotSizeMapping=function(t){var e,n={};return null!=(e=t.sizeMapping)&&e.xl&&(n.xl=t.sizeMapping.xl),null!=(e=t.sizeMapping)&&e.l&&(n.l=t.sizeMapping.l),n.m=null==(e=t.sizeMapping)?void 0:e.m,n.s=null==(e=t.sizeMapping)?void 0:e.s,n.xs=null==(e=t.sizeMapping)?void 0:e.xs,i(i({},t),{sizeMapping:n})},r.prototype.getFuseSlots=function(){var i,o=this;return this.cleaned_fuse_slots||(i=et("fuseMcmOff"),s.fuse_slots=s.fuse_slots.map(function(t){i&&(oe.debug("[SETTINGS]: will".concat(i?"":" NOT"," remove MCM child reference from the slot ref - ").concat(t.slot)),t=o.cleanSlotBasedOnMcmMode(t));var e=t.activateConditionConfig;switch(e.type){case"none":t.activateCondition=void 0;break;case"lazy":var n=o.getCurrentBreakpoint().name,n=e.scrollDistance[n];g(n)||!1===n?t.activateCondition=void 0:t.activateCondition={type:"condition",name:Ht,params:e.scrollDistance};break;case"manual":t.activateCondition={type:"condition",name:te};break;case"custom":t.activateCondition=e.config;break;default:z(e)}return t=o.applyOverrides(t),o.cleanSlotSizeMapping(t)}),this.cleaned_fuse_slots=!0),s.fuse_slots},r.prototype.applyOverrides=function(t){var e;return i(i({},t),{attributes:i(i({},t.attributes),{interscroller:void 0!==(null==(e=this.overrideParams)?void 0:e.interscrollersParams[t.id])||(null==(e=t.attributes)?void 0:e.interscroller),sticky:void 0!==(null==(e=this.overrideParams)?void 0:e.stickiesParams[t.id])||(null==(e=t.attributes)?void 0:e.sticky),dynamic:void 0!==(null==(e=this.overrideParams)?void 0:e.dynamicParams[t.id])||((null==(e=t.attributes)?void 0:e.dynamic)||(null==(e=this.overrideParams)?void 0:e.dynamicParams[t.id])),scrollToStick:void 0!==(null==(e=this.overrideParams)?void 0:e.scrollToStickParams[t.id])||(null==(e=t.attributes)?void 0:e.scrollToStick),miniscroller:void 0!==(null==(e=this.overrideParams)?void 0:e.miniscrollersParams[t.id])||(null==(e=t.attributes)?void 0:e.miniscroller)}),interscrollerAttributes:i(i({},t.interscrollerAttributes),null==(e=this.overrideParams)?void 0:e.interscrollersParams[t.id]),stickyAttributes:i(i({},t.stickyAttributes),null==(e=this.overrideParams)?void 0:e.stickiesParams[t.id]),dynamicAttributes:i(i({},t.dynamicAttributes),null==(e=this.overrideParams)?void 0:e.dynamicParams[t.id]),miniscrollerAttributes:i(i({},t.miniscrollerAttributes),null==(e=this.overrideParams)?void 0:e.miniscrollersParams[t.id])})},r.prototype.getSlotTemplate=function(e){return this.getFuseSlots().filter(function(t){return t.id==e})[0]},r.prototype.isScanDOMOnPageLoad=function(){var t=o.disableAutoLoadSlots;return g(t)||!t},r.prototype.isHeaderBiddingSlot=function(t){return 0<t.bids.length},r.prototype.isSlotWidget=function(t){var e;return(null==(e=t.attributes)?void 0:e.interscroller)||(null==(e=t.attributes)?void 0:e.sticky)||(null==(e=t.attributes)?void 0:e.dynamic)||null},r.prototype.maxSlotHeightForBreakpoint=function(t,e){return null==(t=t.sizeMapping[e])?void 0:t.reduce(function(t,e){return e[1]>t?Number(e[1]):t},0)},r.prototype.getPrebidOptions=function(t){if(this.isPrebidEnabled()&&o.prebid.breakpoint_options){var t=o.prebid.breakpoint_options[t];if(t)return{enabled:t.enabled,sendAllBids:!0===o.prebid.sendAllBids,timeout:null!=(t=null!=(t=t.timeout)?t:o.prebid.defaultTimeout)?t:1e3}}return{enabled:this.isPrebidEnabled(),sendAllBids:!0===o.prebid.sendAllBids,timeout:null!=(t=o.prebid.defaultTimeout)?t:1e3}},r.prototype.isPrebidEnabledAtBP=function(t){return this.isPrebidEnabled()&&this.getPrebidOptions(t).enabled},r.prototype.isUamEnabledAtBP=function(t){return this.isUamEnabled()&&this.getPrebidOptions(t).enabled},r.prototype.getHbTimeout=function(t){return this.getPrebidOptions(t).timeout},r.prototype.isSlotEnabledForBreakpoint=function(t,e){var t=this.getSlotTemplate(t);return!!t&&0<(null!=(t=null==(t=t.sizeMapping)?void 0:t[e])?t:[]).length},r.prototype.getPublicationId=function(){return s.publication_metadata.publication_id},r.prototype.getFuseCDN=function(){return s.fuse_cdn},r.prototype.getPrebidHash=function(){return s.fuse_prebid_hash},r.prototype.getBlockedUrls=function(){return s.fuse_blocked_url||[]},r.prototype.getFuseIndustry=function(){return s.fuse_industry},r.prototype.getFuseSettings=function(){return this.fuseSettings},r.prototype.getEdgeHtmlMaxAdsRefreshLimit=function(){return this.fuseSettings.edgeHtmlMaxAdsRefreshLimit||60},r.prototype.getDefaultRefreshInterval=function(){return this.fuseSettings.refresh},r.prototype.getAccountSettings=function(){return s},r.prototype.getV2CompatOverrides=function(){return this.v2Compatibility},r.prototype.isTestCreatives=function(){return et("fuseTestCreatives")||!1},r.prototype.getSlotTestUrls=function(){return o.fuse_test_urls||[]},r.prototype.getYandexBlockId=function(){return Z("fuseYandexBlockId")||o.yandexBlockId},r.prototype.isYandexEnabled=function(){return o.yandex||et("fuseYandex")||""!==Z("fuseYandexBlockId")};var f=new r(at.getBreakpoints(),l.getViewportInfo());function re(){}re.prototype.getDeviceInfo=function(){return this.deviceInfo||(this.deviceInfo=new Tt(p.getBrowserWindowObject())),this.deviceInfo},re.prototype.getTelemetry=function(){return this.telemetry||(this.telemetry=new Wt(this.getComponentStatusStore(),this.getDeviceInfo(),p.getLogger(),p.getBrowserWindowObject(),p.getSessionId(),this.getReporter(),f)),this.telemetry},re.prototype.getReporter=function(){var t;return this.reporter||(t=p.getFuseDob(),this.reporter=new Pt(t)),this.reporter},re.prototype.getComponentStatusStore=function(){return this.pluginStateStore||(this.pluginStateStore=new Bt(h.onComponentInitEvent,p.getLogger(),this.getReporter())),this.pluginStateStore};var d,a=new re,se={name:"Google Publisher Tag",url:"//securepubads.g.doubleclick.net/tag/js/",file:"gpt.js"},ae="is_refresh",ce="adunit_prev_count",ue="slot_prev_count",le={},de={},ge=!1,b=p.getLogger(),c=p.getBrowserWindowObject(),pe=p.getWindowLocation(),m=a.getReporter(),he=a.getComponentStatusStore(),fe=function(){var t=pe.host;return t.substring(t.length-40,t.length)},be=function(){var t=pe.pathname;return t.substring(t.length-40,t.length)},me=function(){var t=pe.search;return t.substring(t.length-40,t.length)},ye=function(){for(var t=[],e=pe.pathname.split("/"),n=0;n<e.length;n+=1)e[n].length&&-1===e[n].indexOf(".")&&t.push(e[n]);return t},Se=function(t){var e=pe.host,n=pe.pathname,i="false";return t.forEach(function(t){-1<t.indexOf(e+n)&&(i="true")}),i},ve=function(t){c.googletag&&c.googletag._loadStarted_?b.debug("[INIT]: GPT v".concat(d.getVersion()," is already on the page, skip loading another copy")):It(se,function(){b.debug("[INIT]: GPT ".concat(c.googletag&&c.googletag._loadStarted_?"v".concat(d.getVersion()," is loaded"):"not loaded")),t()})},Ie=function(){return c.googletag?c.googletag.cmd||(b.info("[GPT]: Initialised window.googletag.cmd as it was missing"),c.googletag.cmd=[]):c.googletag={cmd:[]},d=c.googletag,c.googletag},y=function(t){return Ie().cmd.push(t)};var Ee=function(t){t.forEach(function(t){var e=t[1],n=e.getSlotElementId(),t=t[0].slotTemplate.id,n=le[n]||0,t=de[t]||0;e.setTargeting(ae,(0<n).toString()),e.setTargeting(ue,n.toString()),e.setTargeting(ce,t.toString())})},we=function(t){t.forEach(function(t){var e=t[1].getSlotElementId(),t=t[0].slotTemplate.id;de[t]=(de[t]||0)+1,le[e]=(le[e]||0)+1})};function Ce(o,r){y(function(){var e,n=[],i=(o.forEach(function(t){var e=function(e){if(!d)return b.error("Called getGPTSlot(".concat(e,") but googletag not defined")),[];if(!e)return b.error("Called getGPTSlot() without a fuseSlotCode"),[];var n,t=d.pubads().getSlots(),i=t.filter(function(t){return 0<=e.indexOf(t.getSlotElementId())});return i.length!==e.length&&(n=t.map(function(t){return t.getSlotElementId()}),t=e.filter(function(t){return-1===n.indexOf(t)}),b.warn("Could not find a GPT slot for all fuse slots.\n      Missing Slots=".concat(JSON.stringify(t),",\n      All GPT Slots: ").concat(JSON.stringify(n)))),i}([t.slotDivId])[0];e&&n.push([t,e])}),n.map(function(t){return t[1]}));function t(){Ee(n);var t=JSON.stringify(i.map(function(t){return t.getSlotElementId()}));m.addAdEvent("gpt_pubads_refresh_".concat(t),r),ge||(m.reportFirstGptRequest(),m.setStateStatus("first_gpt_request"),ge=!0,Fe(Ut(he.state.cmp))),Pe(),b.debug("[AUCTION][".concat(r,"]: Calling googletag.pubads().refresh(").concat(t,")")),d.pubads().refresh(i),we(n)}i&&0!==i.length?!0===Q.isEdgeBrowser(c)?(b.debug("[GC] will trigger GC for iFrames in Edge browser"),e=c.document.querySelectorAll("div[data-fuse] iframe"),new Promise(function(t){setTimeout(function(){try{t()}catch(t){}},5),e.forEach(function(t){t.addEventListener("load",function(){try{for(;this.contentWindow.lastChild;)this.contentWindow.removeChild(this.contentWindow.lastChild);b.debug("[GC]: cleaned iFrame contentWindow")}catch(t){b.error("[GC]: error in cleaning iFrame contentWindow => ".concat(t))}},{once:!0})}),e.forEach(function(t){t.setAttribute("src","about:blank")}),t()}).then(function(){try{CollectGarbage()}catch(t){b.error("[GC]: error in CollectGarbage => ".concat(t))}t()}).catch(function(t){b.error("[GC]: error in purgeIframes => ".concat(t))})):t():b.warn("[AUCTION][".concat(r,"]: Cancelled adserver request because no matching GPT slots found"))})}function Te(t,e){var i,o,n=t.slotDivId,r=(m.addAdEvent("register_gpt_slot_".concat(n)),at.isUseBrowserOuterwidth()),s=r?t.slotTemplate.sizeMapping[l.getViewportInfo().getCurrentBreakpoint().name]:t.slotTemplate.sizes,a=t.slotTemplate.slot,c=d.defineSlot(a,s,n);return c?(r||(r=c,i=t.slotTemplate,o=d.sizeMapping(),Object.keys(i.sizeMapping).forEach(function(t){var e=at.getBreakpoints()[t],n=i.sizeMapping[t];u(e)&&u(n)?(b.debug("[GPT][".concat(i.id,"]: Configuring breakpoint ").concat(t," with mapping ").concat(n)),o.addSize([e,0],n)):b.warn("[GPT][".concat(i.id,"]: Could not configure ").concat(t," because it didn't have a sizeArray"))}),r.defineSizeMapping(o.build())),e.forEach(function(t){c.setTargeting(t.key,t.value)}),c.addService(d.pubads())):b.warn("[GPT]: googletag.defineSlot(".concat(a,", ").concat(JSON.stringify(s),", ").concat(n,") returned null")),c}var S=function(t,e){b.debug("[GPT]: Setting page targeting for [key: ".concat(t,", value: ").concat(e,"]")),d.pubads().setTargeting(t,e)},Ae=function(t,e){y(function(){return S(t,e)})};function _e(t){switch(t._tag){case"ready":return Dt(t.loadFinish);case"deferred":case"disabled":return"disabled";case"cancelled":return t._tag;case"pending":case"loading":return"not_ready";default:z(t)}}var Pe=function(){b.debug("[GPT]: Applying page targeting"),S("fuse_profanity",Se(f.getBlockedUrls())),S("fuse_site",fe()),S("fuse_path",be()),S("fuse_query",me()),S("fuse_category",ye());var t=f.getFuseIndustry(),t=(t&&S("fuse_industry",t),S("testmode","".concat(f.isTestCreatives())),f.getInskinWidth()),t="".concat(u(t)&&c.screen.width>=t),t=(S("inskin_yes",t),S("fuse_uuid",f.getFuseUUID()),S("fuse_publication_id",f.getPublicationId().toString()),u(m.firstGptRequestMs)&&S("GPT_AUCTION_START_MS",Dt(m.firstGptRequestMs)),S("FUSE_LOADED_MS",Dt(m.tagLoadedMs)),S("GPT_READY_MS",_e(he.state.gpt)),S("PREBID_READY_MS",_e(he.state.prebid)),S("UAM_READY_MS",_e(he.state.uam)),S("CMP_DETERMINED_MS",_e(he.state.cmp)),Ft(he.state.cmp));S("CMP_JURISDICTION",t),S("CMP_ALLOW_PERSONAL","".concat(Ut(he.state.cmp)))},Re=function(){y(function(){Pe()})},De=function(){d.pubads().disableInitialLoad(),d.pubads().collapseEmptyDivs(!0),d.pubads().setCentering(!0),d.pubads().enableSingleRequest(),Ue(),Be(),Me(),Pe()};function Oe(t){d.destroySlots(t)}var ke=function(t){y(function(){d.pubads().addEventListener("slotRenderEnded",t)})},xe=function(t){y(function(){d.pubads().addEventListener("slotOnload",t)})},Le=function(t){y(function(){d.pubads().addEventListener("slotResponseReceived",t)})},Ne=function(t){y(function(){d.pubads().addEventListener("slotRequested",t)})},Be=function(){var e=!1;d.pubads().addEventListener("slotOnload",function(t){e||(m.setStateStatus("gpt_first_slot_loaded"),e=!0),t&&(t=t.slot.getSlotElementId(),m.addAdEvent("gpt_slot_loaded_".concat(t)))})},Me=function(){var e=!1;d.pubads().addEventListener("slotRenderEnded",function(t){e||(m.setStateStatus("gpt_first_slot_render_ended"),e=!0),t&&(t=t.slot.getSlotElementId(),m.addAdEvent("gpt_slot_render_ended_".concat(t)))})},Ue=function(){var e=!1;d.pubads().addEventListener("impressionViewable",function(t){e||(m.setStateStatus("gpt_first_impression_viewable"),e=!0),t&&(t=t.slot.getSlotElementId(),b.debug("[EVENT]: AD_IMPRESSION_VIEW for ".concat(t)),m.addAdEvent("gpt_impression_viewable_".concat(t)))})},Fe=function(t){t={nonPersonalizedAds:!t};b.info("[GPT]: googletag.pubads().setPrivacySettings(".concat(JSON.stringify(t),")")),c.googletag.pubads().setPrivacySettings(t)},Ge=p.getLogger(),We=a.getReporter(),ze={name:"Blockthrough",url:"//publift-com.videoplayerhub.com/",file:"galleryplayer.js"};var je={enableIfApplicable:function(t){f.isBlockthroughEnabled()?l.getViewportInfo().isNotXsBreakpoint()?(We.setStateStatus("blockthrough_load_start"),It(ze,function(){Ge.log("[BLOCKTHROUGH]: Tag loaded"),We.setStateStatus("blockthrough_load_finish"),t&&t()})):Ge.debug("[INIT]: Skip loading blockthrough because page on XS breakpoint"):Ge.debug("[INIT]: Skip loading blockthrough because it is not enabled")}},qe="ZVeqITFg3t0RVj7Gh41kEbdx9DA",Ve=p.getLogger(),He=a.getReporter(),Ze=p.getBrowserWindowObject(),Qe=function(t){return{name:"Confiant",url:"//confiant-integrations.global.ssl.fastly.net/".concat(t,"/gpt_and_prebid/"),file:"config.js"}};var Je,Ye={enable:function(t,e){void 0===t&&(t=qe),He.setStateStatus("confiant_load_start"),Ze.confiant=Ze.confiant||{},It(Qe(t),function(){Ve.log("[CONFIANT]: Script loaded"),He.setStateStatus("confiant_load_finish"),e&&e()})}},Ke=this&&this.__assign||function(){return(Ke=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},Xe=this&&this.__spreadArray||function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o<r;o++)!i&&o in e||((i=i||Array.prototype.slice.call(e,0,o))[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))},$e=(tn.prototype.configPrebid=function(t){var e=t.userSync;return Ke(Ke({},t),{userSync:Ke(Ke({},e),{userIds:Xe(Xe([],e.userIds||[],!0),[{name:"id5Id",params:{partner:this.partnerId},storage:{type:"html5",name:"id5id",expires:90,refreshInSeconds:28800}}],!1)})})},tn);function tn(t){this.partnerId=t}var en,nn={UserId5:$e,enable:function(){var t=f.getId5Settings();!Je&&t.enabled&&(Je=new $e(t.partnerId))},getId5Module:function(){return Je}},on=this&&this.__assign||function(){return(on=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},rn=this&&this.__spreadArray||function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o<r;o++)!i&&o in e||((i=i||Array.prototype.slice.call(e,0,o))[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))},sn=(an.prototype.setup=function(){var t,e=this,n=this.browserWindow[this.userIdentityGlobal],i=(n&&("object"===W(i=n)&&null!==i)&&(n.email||n.phoneNumber||n.emailHashes)?(t={placementID:this.placementId},n.email?t.email=n.email:n.phoneNumber?t.phoneNumber=n.phoneNumber:t.emailHashes=n.emailHashes):t={placementID:this.placementId,storageType:"localStorage",detectionType:"scrapeAndUrl",cssSelectors:["input[type=text]","input[type=email]"],detectionSubject:"all",urlParameter:"user_id",logging:"debug"},document.createElement("script")),n=(i.src="https://ats.rlcdn.com/ats.js",i.onload=function(){e.browserWindow.ats.start(t)},this.browserWindow.document.getElementsByTagName("script")[0]);n.parentNode.insertBefore(i,n)},an.prototype.configPrebid=function(t){var e=t.userSync;return on(on({},t),{userSync:on(on({},e),{userIds:rn(rn([],e.userIds||[],!0),[{name:"identityLink",params:{pid:this.placementId},storage:{type:"cookie",name:"idl_env",expires:7}}],!1)})})},an);function an(t,e,n){this.browserWindow=t,this.userIdentityGlobal=e,this.placementId=n}var cn={UserIdentity:sn,enable:function(t){en||(en=new sn(t,f.getFuseSettings().identity.userIdentityGlobal,f.getFuseSettings().identity.placementId)).setup()},getIdentityModule:function(){return en}};function un(){}un.prototype.getPrebidGlobal=function(){return p.getBrowserWindowObject().fusePbjs||(p.getBrowserWindowObject().fusePbjs={que:[]}),p.getBrowserWindowObject().fusePbjs};var ln=new un,dn=this&&this.__assign||function(){return(dn=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},v=p.getLogger(),gn=p.getPackageMajorVersion(),pn=p.getBrowserWindowObject(),I=ln.getPrebidGlobal(),hn=a.getReporter(),fn="https://mpbs.rubiconproject.com/openrtb2/auction",bn="https://mpbs.rubiconproject.com/cookie_sync",mn=function(){var t,e;{if(hn.setStateStatus("prebid_load_script_start"),!I||!I.libLoaded)return t=f.getPrebidHash(),e=f.getFuseCDN(),It(dn({name:"Prebid.org"},t?{url:"//".concat(new URL("https:"+e).hostname,"/prebid/"),file:"prebid-".concat(t,".js")}:{url:"".concat(e).concat(gn,"/").concat(f.getFuseId(),"/"),file:"prebid.js"}),function(){v.debug("[INIT]: Prebid ".concat(I&&I.libLoaded?"".concat(I.version," is loaded and ready"):"not loaded")),hn.setStateStatus("prebid_onload_received")});v.warn("[INIT]: Prebid ".concat(I.version," is already loaded skip loading it again"))}},yn=function(t){I&&I.que?I.que.push(function(){try{t.call(void 0)}catch(t){t instanceof Error?v.error("Error processing command :",t.message,t.stack):v.error("Error processing command :",t)}}):v.error("[PREBID]: No prebid que available")};function Sn(t){return dn(dn(dn({enableSendAllBids:t&&!0===t.sendAllBids,priceGranularity:{buckets:[{max:3,increment:.01,precision:2},{max:10,increment:.1,precision:2},{max:50,increment:1,precision:2},{max:100,increment:10,precision:2}]},sizeConfig:f.isResponsiveEnabled()&&!at.isUseBrowserOuterwidth()?(i=null,o=[],Object.keys(at.getBreakpoints()).forEach(function(t){var e=at.getBreakpoints()[t],n=i?i-1:null;v.debug("[PREBID]: Configured breakpoint ".concat(t," ").concat(e,"px to ").concat(n)),o.push({mediaQuery:"(min-width:".concat(e,"px)").concat(i?" and (max-width: ".concat(n,"px)"):""),sizesSupported:f.getSupportedSizes(t),labels:[t]}),i=e}),o):(e=l.getViewportInfo().getCurrentBreakpoint().name,[{mediaQuery:"(min-width: ".concat(0,"px)"),sizesSupported:f.getSupportedSizes(e),labels:[e]}]),userSync:{filterSettings:{iframe:{bidders:"*",filter:"include"}},enableOverride:!0}},f.isCmpRequired()&&(v.debug("[PREBID]: Configured CMP module"),{consentManagement:{gdpr:{cmpApi:"iab",timeout:f.getUspTimeoutMillis(),defaultGdprScope:f.isStrictCmp(),allowAuctionWithoutConsent:!f.isStrictCmp()},usp:{cmpApi:"iab",timeout:f.getUspTimeoutMillis()}}})),t.sco&&{schain:{validation:"strict",config:{ver:"1.0",complete:1,nodes:[{asi:(e=t.sco).asi,sid:e.sellerId,hp:1}]}}}),0<t.prebidServerBidders.length&&(t=t.prebidServerBidders,v.debug("[PREBID]: Enabling Prebid Server for ".concat(JSON.stringify(t))),{s2sConfig:{accountId:"20884",bidders:t,adapter:"prebidServer",enabled:!0,endpoint:fn,syncEndpoint:bn,timeout:750,extPrebid:{cache:{vastxml:{returnCreative:!1}}}}}));var i,o,e}var vn=function(t){return v.debug("[PREBID]: Applied config settings"),I.setConfig(t),t};var In={loadPrebidLibrary:mn,pushToPrebidQue:yn,setPrebidAdUnits:function(t){var e=l.getViewportInfo().getCurrentBreakpoint(),e=f.getCurrentSizeMapSizes(t.slotTemplate.id,e.name);v.log("[SLOTS]: Setting Prebid ad units for ".concat(t.slotDivId," with sizes ").concat(JSON.stringify(e))),I.addAdUnits({code:t.slotDivId,mediaTypes:{banner:{sizes:e}},bids:t.slotTemplate.bids})},getPrebidDefaultConfig:Sn,setPrebidConfig:vn,getPrebidUnitIndex:function(e){return I&&I.adUnits?I.adUnits.findIndex(function(t){return t.code===e}):void 0},getPrebidUnits:function(t){var n={},i=(I.adUnits.forEach(function(t){return n[t.code]=t}),{});return t.forEach(function(t){var e=n[t];e?i[t]=JSON.parse(JSON.stringify(e)):v.warn("[PREBID]: No prebid unit found for ".concat(t))}),i},enable:function(o){var r=hn.getElapsedTime();mn(),yn(function(){var t,e,n=hn.getElapsedTime()-r,i=f.getPrebidDownloadCutoffMs(),i=g(i)||n<=i;i?(v.debug("[PREBID] Started processing queued fuse tasks"),hn.setStateStatus("prebid_started_processing_queue"),pn.pbjs&&pn.pbjs.libLoaded?pn.pbjs.renderAd||(pn.pbjs.renderAd=I.renderAd):pn.pbjs=I,t=Sn({sendAllBids:f.getPrebidSettings()&&!0===f.getPrebidSettings().sendAllBids,sco:f.getSco(),prebidServerBidders:f.isPrebidServer()?f.getPrebidServerBidders():[]}),e=cn.getIdentityModule(),f.isIdentityEnabled()&&e&&(v.debug("[PREBID] Enabled identity module"),t=e.configPrebid(t)),e=nn.getId5Module(),f.isId5Enabled()&&e&&(v.debug("[PREBID] Enabled id5 module"),t=e.configPrebid(t)),vn(t),v.debug("[PREBID]: Enabled prebid ".concat(JSON.stringify(t)))):v.log("[PREBID]: Not enabling because library took ".concat(n,"ms to download")),o(i)})},reset:function(){I&&I.adUnits&&I.removeAdUnit()}},En=(E.prototype.add=function(t,e){var n=this,i=E.getLCTemplateId(t),o=(Array.isArray(this.slots[i])||(this.slots[i]=[]),this.logger.debug("[GPT-REGISTRY]: Added ".concat(i)),this.slots[i].push(e),this.templateTargetings[i]);o?(Object.keys(o).forEach(function(t){e.setTargeting(t,o[t]),n.logger.debug("[GPT-REGISTRY]: Set targeting. slotTemplateId: ".concat(i,", gpt slot id: ").concat(e.getSlotElementId(),", key: ").concat(t,", value: ").concat(o[t]))}),this.logger.debug("[GPT-REGISTRY]: Applied targeting for ".concat(i," on newly added gpt slot - id: ").concat(e.getSlotElementId()))):this.logger.debug("[GPT-REGISTRY]: No template targeting set for slotTemplateId: ".concat(i))},E.prototype.purgeAll=function(){var e=this;Object.keys(this.slots).forEach(function(t){return e.purge(t)})},E.getLCTemplateId=function(t){return t.toLowerCase()},E.prototype.purge=function(t){var t=E.getLCTemplateId(t),e=(this.logger.debug("[GPT REGISTRY]: Purging ".concat(t)),this.slots[t]);e&&(this.destroySlotsFunc(e),delete this.slots[t],delete this.templateTargetings[t])},E.prototype.purgeByElement=function(t,e){var n=this.getSlots(t)||[],i=n.find(function(t){return t.getSlotElementId()===e});i?(this.destroySlotsFunc([i]),this.slots[E.getLCTemplateId(t)]=n.filter(function(t){return t.getSlotElementId()!==e})):this.logger.warn("[GPT-REGISTRY]: No slot found for key: ".concat(t," code: ").concat(e))},E.prototype.getSlotsLength=function(){return Object.keys(this.slots).length},E.prototype.getSlots=function(t){return t&&"string"==typeof t&&Array.isArray(this.slots[E.getLCTemplateId(t)])?this.slots[E.getLCTemplateId(t)]:[]},E.prototype.addTemplateTargetings=function(t,e,n){t=E.getLCTemplateId(t);this.templateTargetings[t]||(this.templateTargetings[t]={}),this.templateTargetings[t][e]=n},E.prototype.getTemplateTargetings=function(t){t=E.getLCTemplateId(t);return this.templateTargetings[t]||null},E.prototype.setSlotTargetingById=function(e,n,i){var o=this;this.addTemplateTargetings(e,n,i),this.logger.debug("[GPT-REGISTRY]: Template targeting set. slotTemplateId: ".concat(e,", key: ").concat(n,", value: ").concat(JSON.stringify(i))),this.getSlots(e).forEach(function(t){try{t.setTargeting(n,i),o.logger.debug("[GPT-REGISTRY]: Applied template targetings. slot id: ".concat(t.getSlotElementId(),", key: ").concat(n,", value: ").concat(JSON.stringify(i)))}catch(t){t instanceof Error?o.logger.error("[GPT-REGISTRY]: Error occurred while individually setTargeting for slot ".concat(e,"."),t.message,t.stack):o.logger.error("[GPT-REGISTRY]: Error of unexpected type occurred while individually setTargeting for slot ".concat(e,"."))}})},E);function E(t,e){var n=this;this.logger=t,this.gptDestroySlots=e,this.templateTargetings={},this.slots={},this.destroySlotsFunc=function(t){var e=t.map(function(t){return t.getSlotElementId()});n.logger.debug("[GPT-REGISTRY]: Calling googletag.destroySlots(".concat(JSON.stringify(e),")")),n.gptDestroySlots(t)}}function wn(){}wn.prototype.getGptSlotRegistry=function(){return this.gptSlotRegistry||(this.gptSlotRegistry=new En(p.getLogger(),Oe)),this.gptSlotRegistry};var Cn=new wn,Tn=(An.prototype.getInitStatus=function(){var t=this.componentState.state.cmp._tag,e=this.componentState.state.docReadyScan._tag;return{cmpOk:"ready"===t||"disabled"===t,docReady:"ready"==e||"disabled"===e,anyBidLibraryReady:this.isAnyBidLibraryReady()}},An.prototype.isReadyForInit=function(){var t=this.getInitStatus();return 0===Object.values(t).filter(function(t){return!t}).length},An.prototype.checkAndTrigger=function(){g(this.firedInitReady)&&this.isReadyForInit()&&(this.reporter.setStateStatus("initmanager_fired_auction_ready"),this.firedInitReady=this.reporter.getElapsedTime(),this.events.onInitManagerReady.emit({eventType:"onInitManagerReady"}))},An.prototype.isComponentReady=function(t){return"ready"===this.componentState.state[t]._tag},An.prototype.isAnyBidLibraryReady=function(){return"disabled"!==this.componentState.state.yandex._tag?this.isComponentReady("yandex"):this.isComponentReady("prebid")||this.isComponentReady("gpt")||this.isComponentReady("uam")},An.prototype.setTagInitialised=function(){this.state.tag_initialised=!0},An.prototype.isTagInitialised=function(){return this.state.tag_initialised},An.prototype.setIsLowDwellPage=function(t){this.state.on_low_dwell_page=t},An.prototype.isLowDwellPage=function(){return this.state.on_low_dwell_page},An);function An(t,e,n,i){var o=this;this.logger=t,this.reporter=e,this.events=n,this.componentState=i,this.state={tag_initialised:!1,on_low_dwell_page:!1},n.onComponentInitEvent.subscribe(function(t){return o.checkAndTrigger()})}function _n(){}_n.prototype.getInitManager=function(){return this.initManager||(this.initManager=new Tn(p.getLogger(),a.getReporter(),h,a.getComponentStatusStore())),this.initManager};var Pn=new _n,Rn=p.getLogger(),Dn=[];function On(){var t;Rn.info("[TARGETING] Clearing page targeting"),t=Dn,y(function(){t.forEach(function(t){d.pubads().clearTargeting(t.key)})}),Dn=[]}function kn(n,t){var i=-1;Dn.forEach(function(t,e){-1===i&&t.key===n&&(i=e)}),Rn.info("[TARGETING]: Updating custom targeting for [key: ".concat(n,", value: ").concat(t,"]")),-1<i?Dn[i].value=t:Dn.push({key:n,value:t}),Ae(n,t)}Ln.prototype.enableTriggers=function(){this.rootCondition.enableTriggers(this.api)},Ln.prototype.destroy=function(){this.rootCondition.destroyTriggers()},Ln.prototype.checkCondition=function(){return this.rootCondition.checkCondition()},Ln.prototype.checkAndFire=function(){this.firedCallback||this.rootCondition.checkCondition()&&(this.logger.info("[ACTIVATOR][".concat(this.context,"]: Conditions are satisfied. Destroying triggers and invoking callback")),this.rootCondition.destroyTriggers(),this.firedCallback=!0,this.onSatisfiedCB(this.context))};var xn=Ln;function Ln(t,e,n,i,o){this.logger=t,this.context=e,this.rootCondition=n,this.api=i,this.onSatisfiedCB=o,this.firedCallback=!1}Bn.prototype.check=function(){return!0},Bn.prototype.buildTriggers=function(t){return[]};var Nn=Bn;function Bn(){this.name="AlwaysTrue"}Un.prototype.check=function(){return!1},Un.prototype.buildTriggers=function(t){return[]};var Mn=Un;function Un(){this.name="AlwaysFalse"}Gn.prototype.buildTriggers=function(t){return[]},Gn.prototype.check=function(){return this.conditions.reduce(function(t,e){return t&&e.checkCondition()},!0)};var Fn=Gn;function Gn(t){this.conditions=t,this.name="AndCondition"}zn.prototype.buildTriggers=function(t){return[]},zn.prototype.check=function(){return this.conditions.reduce(function(t,e){return t||e.checkCondition()},!1)};var Wn=zn;function zn(t){this.conditions=t,this.name="OrCondition"}(this&&this.__extends||(jn=function(t,e){return(jn=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}jn(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}))(Hn,qn=n);var jn,qn,Vn=Hn;function Hn(t){return qn.call(this,t,t.api.events.onWindowResized,function(t){return!t.crossedBp})||this}var Zn=this&&this.__spreadArray||function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o<r;o++)!i&&o in e||((i=i||Array.prototype.slice.call(e,0,o))[o]=e[o]);return t.concat(i||Array.prototype.slice.call(e))},Qn=(Jn.prototype.checkCondition=function(){return this.checkConditionAndNotify(!1)},Jn.prototype.checkConditionAndNotify=function(t){if(!this.satisfied){try{this.satisfied=this.condition.check(this.id,this.api)}catch(t){return j(t),this.logger.warn("[CONDITION][".concat(this.condition.name,"][").concat(this.id,"]: Caught exception while checking condition"),t.message,t.stack),!1}this.satisfied&&t&&this.activatorCallback()}return this.satisfied},Jn.visitConditions=function(e,n){var i=e.condition;if(i instanceof Fn||i instanceof Wn)i.conditions.forEach(function(t){return Jn.visitConditions(t,n)});else try{n(e)}catch(t){j(t),e.logger.warn("[CONDITION][".concat(i.name,"][").concat(e.id,"]: Caught exception while visiting condition:"),t.message,t.stack)}},Jn.prototype.destroyTriggers=function(){return Jn.visitConditions(this,function(t){t.triggers&&t.triggers.forEach(function(t){t.destroy()})})},Jn.prototype.enableTriggers=function(i){var o=this;return Jn.visitConditions(this,function(t){var e=t.condition,n={id:o.id,api:i,logger:o.logger,onTriggeredCB:function(){return t.checkConditionAndNotify(!0)}};t.triggers=Zn(Zn([],e.buildTriggers(n),!0),[new Vn(n)],!1)})},Jn);function Jn(t,e,n,i,o){this.id=t,this.condition=e,this.api=n,this.activatorCallback=i,this.logger=o,this.triggers=null,this.satisfied=!1}Kn.prototype.buildActivator=function(t,e,n,i){var t=this.buildCondition(e,t,n,function(){return o.checkAndFire()}),o=new xn(this.logger,e,t,n,i);return o},Kn.prototype.registerCondition=function(t,e){if(this.conditions[t])throw Error("Condition with ".concat(t," already registered"));this.conditions[t]=e},Kn.prototype.buildCondition=function(t,e,n,i){var o=e.type;switch(o){case"and":return this.buildBooleanCondition(t,e,n,i,function(t){return new Fn(t)});case"or":return this.buildBooleanCondition(t,e,n,i,function(t){return new Wn(t)});case"condition":case"custom-condition":return this.buildTriggerCondition(t,e,n,i);default:z(o)}},Kn.prototype.buildTriggerCondition=function(t,e,n,i){if(this.internalConditions[e.name])return new Qn(t,this.internalConditions[e.name](),n,i,this.logger);var o=this.conditions[e.name];if(!o)return this.logger.error("[CONDITION-FACTORY]: Could not find condition ".concat(e.name,", it will be deemed false")),this.buildAlwaysFalseCondition(t,n,i);e=new o(null!=(o=e.params)?o:{});return new Qn(t,e,n,i,this.logger)},Kn.prototype.buildAlwaysFalseCondition=function(t,e,n){return new Qn(t,new Mn,e,n,this.logger)},Kn.prototype.buildBooleanCondition=function(e,t,n,i,o){var r=this,t=t.subConditions;if(!t||0===t.length)return this.logger.error("[CONDITION-FACTORY]: Boolean condition with no sub-conditions"),this.buildAlwaysFalseCondition(e,n,i);o=o(t.map(function(t){return r.buildCondition(e,t,n,i)}));return new Qn(e,o,n,i,this.logger)};var Yn=Kn;function Kn(t){this.logger=t,this.internalConditions={AlwaysTrue:function(){return new Nn},AlwaysFalse:function(){return new Mn}},this.conditions={}}var Xn="AbsoluteScrollDistance",$n=(ti.prototype.buildTriggers=function(t){return[new qt(t)]},ti.prototype.check=function(t,e){return e.getWindow().scrollY>=((null==(e=this.params)?void 0:e.pixelsDistance)||0)},ti);function ti(t){this.params=t,this.name=Xn}ni.prototype.destroy=function(){this.window.removeEventListener("readystatechange",this.triggeredCB)};var ei=ni;function ni(t){this.window=t.api.viewportInfo.browserWindow,this.triggeredCB=t.onTriggeredCB,document.addEventListener("readystatechange",this.triggeredCB)}var ii="DocumentStatus",oi=(ri.prototype.buildTriggers=function(t){return[new ei(t)]},ri.prototype.check=function(t,e){return-1!==this.params.state.indexOf(document.readyState)},ri);function ri(t){this.params=t,this.name=ii}ai.prototype.destroy=function(){clearInterval(this.intervalId)};var si=ai;function ai(t,e){this.ctx=t,this.intervalMs=e,this.intervalId=setInterval(this.ctx.onTriggeredCB,this.intervalMs)}var ci="DomElementExists",ui=(li.prototype.buildTriggers=function(t){return[new si(t,250)]},li.prototype.check=function(t,e){return null!==document.querySelector(this.params.selector)},li);function li(t){this.params=t,this.name=ci}var di="PageCount",gi=(pi.prototype.buildTriggers=function(t){return[]},pi.getCountKey=function(t){return"fuse-page-views-".concat(t)},pi.getPageCount=function(t,e){return Number(e.sessionStorage.getItem(pi.getCountKey(t))||0)},pi.incrementPageCount=function(t,e){e.sessionStorage.setItem(pi.getCountKey(t),"".concat(this.getPageCount(t,e)+1))},pi.resetPageCount=function(t,e){e.sessionStorage.setItem(pi.getCountKey(t),"0")},pi.prototype.check=function(t,e){var n;return this.hasChecked||(pi.incrementPageCount(t,e.getWindow()),this.hasChecked=!0,n=pi.getPageCount(t,e.getWindow()),this.isOver=n>=((null==(n=this.params)?void 0:n.pageCount)||1),this.isOver&&pi.resetPageCount(t,e.getWindow())),this.isOver},pi);function pi(t){this.params=t,this.name=di,this.hasChecked=!1,this.isOver=!1}var hi="UrlRegex",fi=(bi.prototype.buildTriggers=function(t){return[]},bi.prototype.check=function(t,e){e=e.getWindow().location.toString().match(this.params.regex);return u(e)&&0<e.length},bi);function bi(t){this.params=t,this.name=hi}var mi="WindowHeightDistance",yi=(Si.prototype.buildTriggers=function(t){return[new qt(t)]},Si.prototype.check=function(t,e){var e=e.getWindow();return e.scrollY>=e.innerHeight*((null==(e=this.params)?void 0:e.windowHeightDistance)||0)},Si);function Si(t){this.params=t,this.name=mi}var vi="WindowValue",Ii=(Ei.prototype.buildTriggers=function(){return[]},Ei.prototype.check=function(t,e){return e.getWindow()[this.params.name]===this.params.value},Ei);function Ei(t){this.params=t,this.name=vi}function wi(t){this.logger=t,this.slotConditionFactory=null,this.insertConditionFactory=null}wi.prototype.getSlotConditionFactory=function(){var t;return this.slotConditionFactory||(this.slotConditionFactory=new Yn(this.logger),(t=this.slotConditionFactory).registerCondition(Xn,$n),t.registerCondition(ci,ui),t.registerCondition(Ht,Zt),t.registerCondition(te,ee),t.registerCondition(di,gi),t.registerCondition(hi,fi),t.registerCondition(mi,yi),t.registerCondition(vi,Ii)),this.slotConditionFactory},wi.prototype.getInsertConditionFactory=function(){var t;return this.insertConditionFactory||(this.insertConditionFactory=new Yn(this.logger),(t=this.insertConditionFactory).registerCondition(ii,oi),t.registerCondition(Xn,$n),t.registerCondition(mi,yi),t.registerCondition(hi,fi),t.registerCondition(ci,ui),t.registerCondition(di,gi),t.registerCondition(vi,Ii)),this.insertConditionFactory};var Ci=new wi(p.getLogger()),Ti=(Ai.prototype.load=function(){this.reporter.setStateStatus("cmp_load_quantcast_start");var t=this,e=this.browserWindow.document.location.hostname,n=this.browserWindow.document.createElement("script"),i=this.browserWindow.document.getElementsByTagName("script")[0],o=this.browserWindow.document.getElementsByTagName("head")[0]||this.browserWindow.document.documentElement,r="https://cmp.quantcast.com".concat("/choice/","PRrmquD1Ggcb1","/",e,"/choice.js?tag_version=V2"),s=new XMLHttpRequest;s.onreadystatechange=function(){4===this.readyState&&(n.async=!0,n.type="text/javascript",200===this.status?n.src=r:t.logger.error("GET call to CMP script with ".concat(e," responed with the status code - ").concat(this.status)),i&&i.parentNode?i.parentNode.insertBefore(n,i):(t.logger.debug("First script element not fully initialised, falling back to head-based insertion"),o.insertBefore(n,o.firstChild)))},s.open("GET",r,!0),s.send()},Ai);function Ai(t,e,n){this.logger=t,this.browserWindow=e,this.reporter=n}Pi.prototype.generate=function(){this.createStubFunctionV2()},Pi.prototype.createStubFunctionV2=function(){var s=this;s.logger.debug("[CMP]: Generating V2 stub");for(var t,o="__tcfapiLocator",n=[],r=s.browserWindow,e=function t(){var e,n=r.document,i=!!r.frames[o];return i?s.logger.debug("[CMP] Found existing version 2 stub"):(s.logger.debug("[CMP] Version 2 stub not found - generating"),n.body?((e=n.createElement("iframe")).style.cssText="display:none",e.name=o,n.body.appendChild(e)):setTimeout(t,5)),!i},i=r;i;){try{if(i.frames[o]){t=i,s.logger.debug("[CMP] Found locator frame");break}}catch(t){"{}"!==JSON.stringify(t)&&s.logger.log("[CMP]:",JSON.stringify(t))}if(i===s.browserWindow.top)break;i=i.parent}t||(s.logger.debug("[CMP] Locator frame not found"),e(),r.__tcfapi=function(){var t,e=arguments;if(!e.length)return n;"setGdprApplies"===e[0]?3<e.length&&2===e[2]&&"boolean"==typeof e[3]&&(t=e[3],"function"==typeof e[2]&&e[2]("set",!0)):"ping"===e[0]?"function"==typeof e[2]&&e[2]({gdprApplies:t,cmpLoaded:!1,cmpStatus:"stub"}):(t="init"===e[0]&&"object"===W(e[3])?[e[0],e[1],e[2],Object.assign(e[3],{tag_version:"V2"})].concat(Array.from(e).slice(4)):e,n.push(t))},r.addEventListener("message",function(i){var o="string"==typeof i.data,t={};try{t=o?JSON.parse(i.data):i.data}catch(t){"{}"!==JSON.stringify(t)&&s.logger.error("[CMP]:",JSON.stringify(t))}var r=t.__tcfapiCall;r&&s.browserWindow.__tcfapi(r.command,r.version,function(t,e){var n,t={__tcfapiReturn:{returnValue:t,success:e,callId:r.callId}};o&&(n=JSON.stringify(t)),i&&i.source&&i.source.postMessage&&i.source.postMessage(n,"*")},r.parameter)},!1))};var _i=Pi;function Pi(t,e){this.logger=t,this.browserWindow=e}Di.prototype.checkForCCPA=function(n){var i=this;this.browserWindow.__uspapi("uspPing",1,function(t,e){e&&t.mode.includes("USP")&&t.jurisdiction.includes(t.location.toUpperCase())?(i.logger.log("[CMP-V2]: CCPA Region"),i.browserWindow.__uspapi("setUspDftData",1,function(t,e){i.logger.log("[CMP-V2]: Setting up data for USP API",JSON.stringify(t),e),i.browserWindow.__uspapi("getUSPData",1,function(t,e){if(!e)return i.logger.log("[CMP-V2]: Failed retrieving USP data use default instead"),n({applies:!0,privacyString:"1---"});n({applies:!0,privacyString:t.uspString})})})):n({applies:!1})})},Di.prototype.setGDPRConsentPrompt=function(){var t=this;this.consentUIPrompt.setup("Privacy Settings",function(){t.browserWindow.__tcfapi("displayConsentUi",2,function(){return t.logger.log("[CMP-V2]: GDPR Consent UI displayed")})})},Di.prototype.setCCPAConsentPrompt=function(){var t=this;this.consentUIPrompt.setup("Do Not Sell My Data",function(){t.browserWindow.__uspapi("displayUspUi")})},Di.prototype.cmpLoaded=function(e){var n=!1;setTimeout(function(){if(!n)return e(!1)},1e3),this.browserWindow.__tcfapi("ping",2,function(t){return n=!0,t&&t.cmpLoaded?e(!0):e(!1)})},Di.prototype.getConsentData=function(n){var i=this;this.browserWindow.__tcfapi("getTCData",2,function(t,e){return i.callCount++,e&&t?g(t.gdprApplies)||"loading"===(null==t?void 0:t.cmpStatus.toLowerCase())?n({dataAvailable:!0,gdprApplies:void 0,cmpStatus:null==t?void 0:t.cmpStatus,eventStatus:null==t?void 0:t.eventStatus}):!1===t.gdprApplies?n({dataAvailable:!0,gdprApplies:!1,cmpStatus:null==t?void 0:t.cmpStatus,eventStatus:null==t?void 0:t.eventStatus}):!0===t.gdprApplies?i.handleGdprApplies(t,n):void i.logger.warn("[CMP-V2]: Unexpected gdprApplies status. Data: ".concat(JSON.stringify(t))):n({dataAvailable:!1,cmpStatus:null==t?void 0:t.cmpStatus,eventStatus:null==t?void 0:t.eventStatus})})},Di.prototype.handleGdprApplies=function(t,e){var n,i,o,r,s=t.eventStatus.toLowerCase();return"useractioncomplete"===s||"tcloaded"===s?(n=(null==(n=null==(n=t.purpose)?void 0:n.consents)?void 0:n[2])||(null==(n=t.purposeConsents)?void 0:n[2]),i=(null==(i=null==(i=t.purpose)?void 0:i.consents)?void 0:i[3])||(null==(i=t.purposeConsents)?void 0:i[3]),o=!g(n),r=!g(i),r=(o=o&&r)&&n&&i,this.logger.debug("[CMP-V2]: Purposes available: ".concat(o,", Consent: ").concat(r," Data: ").concat(JSON.stringify(t))),e({dataAvailable:!0,gdprChoiceReceived:!0,personalisedAdsConsent:r,gdprApplies:!0,cmpStatus:null==t?void 0:t.cmpStatus,eventStatus:null==t?void 0:t.eventStatus})):("cmpuishown"===s||this.callCount%8==0&&this.logger.warn("[CMP-V2]: Unexpected eventStatus. Data: ".concat(JSON.stringify(t))),e({dataAvailable:!0,gdprChoiceReceived:!1,gdprApplies:!0,cmpStatus:null==t?void 0:t.cmpStatus,eventStatus:null==t?void 0:t.eventStatus}))},Di.prototype.createUspStub=function(){function e(){var t=arguments;W(o.__uspapi)!==e?setTimeout(function(){void 0!==o.__uspapi&&o.__uspapi.apply(o.__uspapi,t)},500):(i.warn("[CMP-V2] USP is still in stub mode. Calling to ".concat(t[0]," API will be unsuccessful")),"function"==typeof t[2]&&t[2](void 0,!1))}var t,n=this,i=this.logger,o=this.browserWindow;void 0===o.__uspapi&&(o.__uspapi=e,t=setInterval(function(){n.uspTries++,o.__uspapi!==e?(i.debug("[CMP-V2]: USP stub function has been replaced"),clearInterval(t)):n.uspTries<n.uspTriesLimit?i.debug("[CMP-V2]: USP stub function has NOT been replaced, will retry"):(i.warn("[CMP-V2]: USP stub function has NOT been replaced, but the timeout has been reached"),clearInterval(t))},300))};var Ri=Di;function Di(t,e,n){this.logger=t,this.consentUIPrompt=n,this.uspTries=0,this.uspTriesLimit=3,this.callCount=-1,this.browserWindow=e,this.createUspStub()}w.prototype.enable=function(){this.componentStateStore.updateState("cmp",Lt(this.reporter.getElapsedTime())),this.generateStubs(),this.loadVersion()},w.prototype.generateStubs=function(){this.stubFunctionsGenerator.generate()},w.prototype.loadVersion=function(){this.reporter.setStateStatus("cmp_load_wait_start"),this.logger.info("[CMP]: Wait for CMP to load"),this.checkForVersion2()},w.prototype.versionLoader=function(t){var e=this,n=t.found,t=t.versionNumber;u(this.version)?this.logger.warn("[CMP]: Version already loaded: ".concat(t)):n?2===t?(this.reporter.setStateStatus("cmp_load_wait_finish"),this.logger.debug("[CMP]: Loaded version ".concat(t)),this.version=new Ri(this.logger,this.browserWindow,this.consentUIPrompt),this.handleCmpLoaded()):(this.logger.warn("[CMP]: Version ".concat(t," is not supported, disabling personalisation")),this.setDetermination("none",!0,!0)):(++this.cmpLoadCounter%10==0&&this.logger.debug("[CMP] Waiting for load"),setTimeout(function(){return e.checkForVersion2()},50))},w.prototype.checkForVersion2=function(){var e=this;this.browserWindow.__tcfapi("ping",null,function(t){e.versionLoader({found:t.cmpLoaded,versionNumber:2})})},w.prototype.checkForCCPA=function(t){this.version.checkForCCPA(t)},w.prototype.cmpLoaded=function(t){if(!u(this.version))return t(!1);this.version.cmpLoaded(t)},w.prototype.getConsentData=function(t){this.version.getConsentData(t)},w.prototype.setGDPRConsentPrompt=function(){this.version.setGDPRConsentPrompt()},w.prototype.setCCPAConsentPrompt=function(){this.version.setCCPAConsentPrompt()},w.prototype.setNonPrivacyRegionsPrompt=function(){this.consentUIPrompt.setup("You are outside the CCPA jurisdiction.")},w.prototype.handleGdprNotApplies=function(){var n,i=this,o=(this.logger.info("[CMP]: GDPR does not apply"),!1);setTimeout(function(){o||(o=!0,i.reporter.setStateStatus("cmp_check_for_ccpa_timeout"),i.logger.warn("[CMP]: USP API is not responding, continue as if not in CCPA region"),i.setDetermination("none",!0,!0))},2e3),this.reporter.setStateStatus("cmp_check_for_ccpa_start"),this.checkForCCPA(function(t){var e=t.applies,t=t.privacyString;o?i.logger.warn("[CMP]: Got CCPA response, but timeout already reached"):(o=!0,i.reporter.setStateStatus("cmp_check_for_ccpa_finish"),e?(i.setCCPAConsentPrompt(),n="Y"===t[2].toUpperCase(),i.logger.info("[CMP]: CCPA applies. disablePersonalisation: ".concat(n)),i.setDetermination("ccpa",!n,!1)):(i.logger.info("[CMP]: Not in CCPA region, continue with personalisation"),i.setNonPrivacyRegionsPrompt(),i.setDetermination("none",!0,!1)))})},w.prototype.handleGdprApplies=function(){var o,r,s=this,a=(this.logger.log("[CMP]: GDPR applies, checking if personalisation is allowed"),this.reporter.setStateStatus("cmp_gdpr_choice_wait_start"),!1);this.getConsentData(function(t){var e=t.gdprChoiceReceived,t=t.personalisedAdsConsent;e&&(a=!0,s.reporter.setStateStatus("cmp_gdpr_choice_wait_finish"),s.logger.info("[CMP]: GDPR decision received via short-circuit. Allow personalisation: ".concat(t)),s.setDetermination("gdpr",t,!1))}),a||(o=0,this.setGDPRConsentPrompt(),r=setInterval(function(){s.getConsentData(function(t){var e=t.gdprChoiceReceived,n=t.personalisedAdsConsent,i=t.cmpStatus,t=t.eventStatus;e?(a=!0,s.reporter.setStateStatus("cmp_gdpr_choice_wait_finish"),s.logger.info("[CMP]: GDPR decision received. Allow personalisation: ".concat(n)),clearInterval(r),s.setDetermination("gdpr",n,!1)):++o%10==0&&s.logger.info("[CMP]: Waiting for GDPR personalisation choice. cmpStatus: ".concat(i,", eventStatus: ").concat(t))})},100))},w.prototype.handleCmpLoaded=function(){function o(t){r.reporter.setStateStatus("cmp_gdpr_applies_check_finish"),!1===t?r.handleGdprNotApplies():r.settings.isRequestGdprPersonalisation()?r.handleGdprApplies():(r.reporter.setStateStatus("cmp_gdpr_choice_wait_finish"),r.logger.info("[CMP]: The GDPR applies, but we will assume they do not allow personalisation"),r.setDetermination("gdpr",!1,!1))}var r=this;this.logger.info("[CMP]: Checking if the GDPR applies"),this.reporter.setStateStatus("cmp_gdpr_applies_check_start");this.getConsentData(function(t){var e,n,i,t=t.gdprApplies;g(t)?(e=0,r.logger.debug("[CMP]: Setting a check interval of ".concat(250,"ms")),n=!1,i=setInterval(function(){r.getConsentData(function(t){t=t.gdprApplies;g(t)?e++%4==0&&r.logger.info("[CMP]: Waiting for GDPR determination"):(clearInterval(i),n||(n=!0,o(t)))})},250)):(r.logger.debug("[CMP]: GDPR status already available, processing immediately"),o(t))})},w.prototype.setDetermination=function(t,e,n){var i=this.componentStateStore.state.cmp._tag;"loading"==i?(t={jurisdiction:t,timeout:n,allowPersonalisation:e},this.logger.info("[CMP]: Determination: ".concat(JSON.stringify(t))),n=this.reporter.getElapsedTime(),this.componentStateStore.updateState("cmp",Nt(this.componentStateStore.state.cmp,n,t))):this.logger.error("[CMP]: CMP in unexpected state: ".concat(i))};var Oi=w;function w(t,e,n,i,o,r,s){this.logger=e,this.reporter=n,this.stubFunctionsGenerator=i,this.consentUIPrompt=o,this.componentStateStore=r,this.settings=s,this.cmpLoadCounter=0,this.browserWindow=t}xi.prototype.setup=function(t,e){var n,i=this.browserWindow.document.querySelector(this.domSelector);i&&(e?((n=document.createElement("a")).href="javascript:void(0)",n.id=this.elementId,n.innerHTML=t,n.addEventListener("click",e),i.appendChild(n)):i.textContent=t)};var ki=xi;function xi(t,e,n){void 0===e&&(e="div[data-fuse-privacy-tool]"),void 0===n&&(n="fuse-privacy-tool"),this.browserWindow=t,this.domSelector=e,this.elementId=n}function Li(){}Li.prototype.getStubFunctionsGenerator=function(){return this.stubFunctionsGenerator||(this.stubFunctionsGenerator=new _i(p.getLogger(),p.getBrowserWindowObject())),this.stubFunctionsGenerator},Li.prototype.getConsentManger=function(){return this.consentManager||(this.consentManager=new Oi(p.getBrowserWindowObject(),p.getLogger(),a.getReporter(),this.getStubFunctionsGenerator(),new ki(p.getBrowserWindowObject()),a.getComponentStatusStore(),f)),this.consentManager},Li.prototype.getQuantcastLoader=function(){return this.quantcastLoader||(this.quantcastLoader=new Ti(p.getLogger(),p.getBrowserWindowObject(),a.getReporter())),this.quantcastLoader};var Ni=new Li,Bi=(Mi.prototype.code=function(){return"1---"},Mi);function Mi(){}Fi.prototype.loadAmazonUam=function(n,i,t,e,o,r){var s;function a(t,e){i[n]._Q.push([t,e])}i[n]||(i[n]={init:function(){a("i",arguments)},fetchBids:function(){a("f",arguments)},setDisplayBids:function(){},targetingKeys:function(){return[]},_Q:[]},(s=t.createElement(e)).async=!0,s.src=o,"function"==typeof r&&(s.readyState?s.onreadystatechange=function(){"loaded"!==s.readyState&&"complete"!==s.readyState||(s.onreadystatechange=null,r())}:s.onload=function(){r()}),(o=t.getElementsByTagName(e)[0]).parentNode.insertBefore(s,o))},Fi.prototype.load=function(t,e){var n=this;if(this.logger.debug("[UAM]: Loading script"),this.reporter.setStateStatus("uam_script_load_start"),this.loadAmazonUam("apstag",this.browserWindow,this.browserWindow.document,"script","//c.amazon-adsystem.com/aax2/apstag.js",function(){n.reporter.setStateStatus("uam_script_load_finish"),n.init(t,e)}),!this.browserWindow.apstag)return this.logger.error("[INIT]: UAM script load failed.")},Fi.prototype.init=function(t,e){var n=this;this.reporter.setStateStatus("uam_initialise_start"),this.browserWindow.apstag.init(this.getUamConfig(t),function(){n.logger.info("[UAM]: Initialisation finished"),n.reporter.setStateStatus("uam_initialise_finish"),e()})},Fi.prototype.getUamConfig=function(t){var e={pubID:this.pubId,adServer:this.adServer};return t||(e.gdpr={cmpTimeout:0}),!g(this.sco)&&Object.getOwnPropertyNames(this.sco).length&&(e.schain={ver:"1.0",complete:1,nodes:[{asi:this.sco.asi,sid:this.sco.sellerId,hp:1}]}),e},Fi.prototype.makeBids=function(t,e){var n=this;this.browserWindow.apstag.fetchBids({slots:t},function(t){n.gptPushFn(function(){n.browserWindow.apstag.setDisplayBids(),e(t)})})};var Ui=Fi;function Fi(t,e,n,i,o,r,s,a){this.pubId=t,this.adServer=e,this.logger=n,this.browserWindow=i,this.consentManager=o,this.reporter=r,this.gptPushFn=s,this.sco=a}function Gi(){}Gi.prototype.getCcpaPrivacyStringCoder=function(){return new Bi},Gi.prototype.getUamAdServer=function(){return"googletag"},Gi.prototype.getSco=function(){return f.getSco()},Gi.prototype.getUam=function(){return this.uam||(this.uam=new Ui(f.getUamSettings().pubID,Wi.getUamAdServer(),p.getLogger(),p.getBrowserWindowObject(),Ni.getConsentManger(),a.getReporter(),y,Wi.getSco())),this.uam};var Wi=new Gi;ji.prototype.plan=function(t,e){var n=this,i="".concat(++this.auctionCounter),o=this.viewportInfo.getCurrentBreakpoint().name,r=this.settings.getHbTimeout(o),s=void 0!==r,a=this.isLowDwellPage(),c=this.settings.isUamEnabledAtBP(o)&&s,s=this.settings.isPrebidEnabledAtBP(o)&&s,u=(c||s||this.logger.debug("[PLANNER][".concat(i,"]: Headerbidding is not configured at breakpoint ").concat(o)),this.getMaxOffset(e)),e=this.settings.getAuctionMaxSlots(),t=this.sortSlotsByViewport(i,t).filter(function(t){return t.zoneDiv.getBoundingClientRect().top<u}).slice(0,e),e=t.filter(function(t){return n.settings.isHeaderBiddingSlot(t.slotTemplate)}),l=0<e.length;return{auctionId:i,usePrebid:!a&&this.isUsePrebid(s,i,l),useUam:!a&&this.isUseUam(c,i,l),hbTimeout:r,hbSlots:e,breakpointName:o,gptSlots:t}},ji.prototype.sortSlotsByViewport=function(t,e){var e=e.sort(function(t,e){t=t.zoneDiv.getBoundingClientRect(),e=e.zoneDiv.getBoundingClientRect();return t.top-e.top}),n=e.map(function(t){return t.slotDivId});return this.logger.debug("[PLANNER][".concat(t,"]: Slot priority order: ").concat(JSON.stringify(n))),e},ji.prototype.getMaxOffset=function(t){var e=this.viewportInfo.getViewportStatus(),n=e.offset,e=e.innerHeight;return t?n.y+e+e*t:1/0},ji.prototype.isUseUam=function(t,e,n){var i="ready"===this.componentStateStore.state.uam._tag;return t&&!i?this.logger.info("[AUCTION][".concat(e,"]: UAM has not finished loading and will be excluded from the auction")):t&&!n&&this.logger.debug("[AUCTION][".concat(e,"]: UAM has been excluded from the auction because no headerbidding slots are enabled")),t&&i&&n},ji.prototype.isUsePrebid=function(t,e,n){var i="ready"===this.componentStateStore.state.prebid._tag;return t&&!i?this.logger.info("[AUCTION][".concat(e,"]: Prebid has not finished loading and will be excluded from the auction")):t&&!n&&this.logger.debug("[AUCTION][".concat(e,"]: Prebid has been excluded from the auction because no headerbidding slots are enabled")),t&&i&&n};var zi=ji;function ji(t,e,n,i,o){this.logger=t,this.settings=e,this.viewportInfo=n,this.isLowDwellPage=i,this.componentStateStore=o,this.auctionCounter=0}var qi,Vi,Hi=this&&this.__assign||function(){return(Hi=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},Zi=((n=qi=qi||{}).GPT_REQUEST="GPT_REQUEST",n.GPT_RESPONSE="GPT_RESPONSE",n.GPT_RENDERED="GPT_RENDERED",n.GPT_LOADED="GPT_LOADED",n.CANCELLED="CANCELLED",n.SUPERSEDED="SUPERSEDED",(n=Vi=Vi||{})[n.PREBID_REQUEST=0]="PREBID_REQUEST",n[n.PREBID_RESPONSE=1]="PREBID_RESPONSE",n[n.PREBID_SKIPPED=2]="PREBID_SKIPPED",n[n.UAM_REQUEST=3]="UAM_REQUEST",n[n.UAM_RESPONSE=4]="UAM_RESPONSE",n[n.UAM_SKIPPED=5]="UAM_SKIPPED",n[n.GPT_REQUEST=6]="GPT_REQUEST",n[n.CANCELLED=7]="CANCELLED",C.prototype.createNewAuction=function(t,e,n){this.auctions[t.auctionId]={started:this.reporter.getElapsedTime(),creativeDivIds:t.gptSlots.map(function(t){return t.slotDivId}),slotNames:t.gptSlots.map(function(t){return t.slotTemplate.slot}),hbDivIds:t.hbSlots.map(function(t){return t.slotDivId}),uamIncluded:t.useUam,uamResponded:!1,uamSkipped:!1,prebidIncluded:t.usePrebid,prebidResponded:!1,prebidSkipped:!1,uamCancelled:!1,prebidCancelled:!1,gptRequestSent:!1,auctionPhaseCallback:e,slotStatus:t.gptSlots.reduce(function(t,e){return Hi(Hi({},t),((t={})[e.slotDivId]={slotPhaseCallback:function(t){return n(e,t)}},t))},{})}},C.prototype.getAuctionStatus=function(t){return this.auctions[t]},C.prototype.getActiveGptCalls=function(){return Object.keys(this.activeGptCalls)},C.prototype.getSlotStatus=function(t,e){return this.auctions[t].slotStatus[e]},C.prototype.getSlotStatusInferredAuction=function(t,e){var n=this.activeGptCalls[t];if(n)return this.auctions[n].slotStatus[t];this.logger.debug("[AUCTION-STATUS][".concat(e,"]: Could not find active GPT call for ").concat(t))},C.prototype.onPrebidRequest=function(t){t=this.auctions[t];t.prebidRequestTime=this.reporter.getElapsedTime(),t.auctionPhaseCallback(Vi.PREBID_REQUEST)},C.prototype.onPrebidResponse=function(t){t=this.auctions[t];t.prebidResponseTime=this.reporter.getElapsedTime(),t.prebidResponded=!0,t.auctionPhaseCallback(Vi.PREBID_RESPONSE)},C.prototype.onPrebidSkipped=function(t){t=this.auctions[t];t.prebidSkipped=!0,t.auctionPhaseCallback(Vi.PREBID_SKIPPED)},C.prototype.onUamRequest=function(t){t=this.auctions[t];t.uamRequestTime=this.reporter.getElapsedTime(),t.auctionPhaseCallback(Vi.UAM_REQUEST)},C.prototype.onUamSkipped=function(t){t=this.auctions[t];t.uamSkipped=!0,t.auctionPhaseCallback(Vi.UAM_SKIPPED)},C.prototype.onUamResponse=function(t){t=this.auctions[t];t.uamResponseTime=this.reporter.getElapsedTime(),t.uamResponded=!0,t.auctionPhaseCallback(Vi.UAM_RESPONSE)},C.prototype.cancelAuction=function(t){t=this.auctions[t];t.cancelled=this.reporter.getElapsedTime(),t.auctionPhaseCallback(Vi.CANCELLED)},C.prototype.removeFromGptActive=function(t){var e=this.activeGptCalls[t];e?(this.logger.debug("[AUCTION][".concat(e,"]: Removed ").concat(t," from GPT active list")),delete this.activeGptCalls[t]):this.logger.debug("[AUCTION]: Could not find ".concat(t," in the GPT active list"))},C.prototype.onGptRequest=function(n,t){var i=this;t.forEach(function(t){var e=i.getSlotStatus(n,t);e&&(e.gptRequestTime=i.reporter.getElapsedTime(),e.slotPhaseCallback(qi.GPT_REQUEST),(e=i.activeGptCalls[t])&&(i.logger.warn("[AUCTION][".concat(n,"]: ").concat(t," is part of an uncompleted auction: ").concat(e," and is marked superseded")),i.auctions[e].slotStatus[t].supersededTime=i.reporter.getElapsedTime(),i.auctions[e].slotStatus[t].slotPhaseCallback(qi.SUPERSEDED)),i.activeGptCalls[t]=n)}),this.auctions[n].gptRequestSent=!0,this.auctions[n].auctionPhaseCallback(Vi.GPT_REQUEST)},C.prototype.onGptResponse=function(t){t=this.getSlotStatusInferredAuction(t,qi.GPT_RESPONSE);t&&(t.gptResponseTime=this.reporter.getElapsedTime(),t.slotPhaseCallback(qi.GPT_RESPONSE))},C.prototype.onGptSlotRendered=function(t,e){var n=this.getSlotStatusInferredAuction(t,qi.GPT_RENDERED);n&&(n.gptOnRenderTime=this.reporter.getElapsedTime(),e||this.removeFromGptActive(t),n.slotPhaseCallback(qi.GPT_RENDERED))},C.prototype.onGptSlotLoaded=function(t){var e=this.getSlotStatusInferredAuction(t,qi.GPT_LOADED);e&&(e.gptOnLoadTime=this.reporter.getElapsedTime(),this.removeFromGptActive(t),e.slotPhaseCallback(qi.GPT_LOADED))},C.prototype.cancelSlotAuction=function(t,e,n){this.logger.info("[AUCTION][".concat(t,"]: Cancelled auction for ").concat(e," because ").concat(n));n=this.getSlotStatus(t,e);n&&(n.cancelledTime=this.reporter.getElapsedTime(),this.removeFromGptActive(e),n.slotPhaseCallback(qi.CANCELLED))},C.prototype.getAuctions=function(){return this.auctions},C);function C(t,e){this.logger=t,this.reporter=e,this.auctions={},this.activeGptCalls={}}T.prototype.sendGptRequest=function(t,e){var n=this,i=this.fuseSlotRegistry.filterUndeleted(t,function(t){n.auctionState.cancelSlotAuction(e,t,"slot DOM element was deleted")});this.auctionState.onGptRequest(e,t),this.fuseSlotRegistry.clearFuseSkins(),Ce(this.fuseSlotRegistry.getSlots(i),e)},T.prototype.handleHBResponse=function(t,e,n){var i,o,r=this.auctionState.getAuctionStatus(t);r.gptRequestSent?e&&this.logger.debug("[AUCTION][".concat(t,"]: Received ").concat(e," bid after adserver request already sent")):(i=r.prebidIncluded,o=r.uamIncluded,n?(this.logger.info("[AUCTION][".concat(t,"]: Timeout reached with missing responses, sending to GPT.\n          Status: ").concat(JSON.stringify(r))),this.sendGptRequest(r.creativeDivIds,t)):o&&i?(r.uamResponded||r.uamCancelled)&&(r.prebidResponded||r.prebidCancelled)?(this.logger.info("[AUCTION][".concat(t,"]: All necessary responses received, sending to GPT")),this.sendGptRequest(r.creativeDivIds,t)):this.logger.debug("[AUCTION][".concat(t,"]: Still waiting for responses. Status: ").concat(JSON.stringify(r))):(this.logger.debug("[AUCTION][".concat(t,"]: ").concat(e," complete, calling GPT")),this.sendGptRequest(r.creativeDivIds,t)))},T.prototype.setAuctionTimeout=function(t,e){var n=this,t=t+250;this.logger.debug("[AUCTION][".concat(e,"]: Set auction failure timeout of ").concat(t)),setTimeout(function(){return n.handleHBResponse(e,null,!0)},t)},T.prototype.startPrebidAuction=function(i,t,e){var o=this,r=t.map(function(t){return t.code}),n=JSON.stringify(r);this.reporter.addAdEvent("prebid_request_".concat(n),i),this.logger.info("[AUCTION][".concat(i,"]: Requesting prebid for: ").concat(n)),this.logger.debug("[AUCTION][".concat(i,"]: Prebid request details: ").concat(JSON.stringify(t))),0<t.length?(this.firstPrebidRequest||(this.firstPrebidRequest=!0,this.reporter.setStateStatus("first_prebid_request")),this.prebidGlobal.requestBids({auctionId:i,adUnits:t,timeout:e,bidsBackHandler:function(t,e){o.auctionState.onPrebidResponse(i);var n=Object.keys(t);o.logger.info("[AUCTION][".concat(i,"]: Prebid auction complete. Any-bidder-timedout?=").concat(e,". Responding slots: ").concat(JSON.stringify(n))),0<n.length?o.logger.debug("[AUCTION][".concat(i,"]: Prebid response details: "),JSON.stringify(t)):o.logger.warn("[AUCTION][".concat(i,"]: No bid responses received from prebid")),o.reporter.addAdEvent("prebid_response_".concat(JSON.stringify(n)),i),o.firstPrebidResponse||(o.firstPrebidResponse=!0,o.reporter.setStateStatus("first_prebid_response"));try{o.prebidGlobal.setTargetingForGPTAsync(r),o.handleHBResponse(i,"prebid",!1)}catch(t){o.logger.error("[AUCTION][".concat(i,"]: ").concat(t.message," ").concat(t.stack))}}})):(this.logger.info("[AUCTION][".concat(i,"]: Skipped prebid call because no eligible slots available")),this.auctionState.onPrebidSkipped(i))},T.prototype.startUamAuction=function(e,t){var n,i=this;t.length?(n=JSON.stringify(t.map(function(t){return t.slotID})),this.reporter.addAdEvent("uam_request_".concat(n),e),this.logger.info("[AUCTION][".concat(e,"]: Sending UAM request for ").concat(n)),this.logger.debug("[AUCTION][".concat(e,"]: Sending UAM request with slot details: ").concat(JSON.stringify(t))),this.firstUamRequest||(this.firstUamRequest=!0,this.reporter.setStateStatus("first_uam_request")),this.uam.makeBids(t,function(t){i.logger.info("[AUCTION][".concat(e,"]: Received UAM response")),i.logger.debug("[AUCTION][".concat(e,"]: UAM response details: "),JSON.stringify(t)),i.reporter.addAdEvent("uam_response_".concat(n),e),i.firstUamResponse||(i.firstUamResponse=!0,i.reporter.setStateStatus("first_uam_response")),i.auctionState.onUamResponse(e),i.handleHBResponse(e,"uam",!1)})):(this.logger.debug("[AUCTION][".concat(e,"]: Skipped UAM bid because no UAM slots found")),this.auctionState.onUamSkipped(e))},T.prototype.startGptOnlyAuction=function(t,e){this.logger.debug("[AUCTION][".concat(t,"]: Starting GPT-only auction")),this.sendGptRequest(e,t)},T.prototype.prepareUamRequest=function(t,e){var n=this;return e.map(function(t){var e=n.settings.getCurrentSizeMapSizes(t.slotTemplate.id,t.breakpoint);return{slotID:t.slotDivId,slotName:t.slotTemplate.slot,sizes:e}})},T.prototype.preparePrebidRequest=function(i,t){var o=this,e=t.map(function(t){return t.slotDivId}),r=[],s=In.getPrebidUnits(e);return t.forEach(function(t){var e=o.settings.getCurrentSizeMapSizes(t.slotTemplate.id,t.breakpoint),n=s[t.slotDivId];n?(r.push(n),n.mediaTypes||(n.mediaTypes={}),n.mediaTypes.banner||(n.mediaTypes.banner={}),n.mediaTypes.banner.sizes=e):o.logger.debug("[AUCTION][".concat(i,"]: Could not find prebid unit for ").concat(t.slotDivId))}),r},T.prototype.executeAuction=function(e,t,n){var i,o=this,r=e.auctionId,s=e.gptSlots.map(function(t){return t.slotDivId});this.auctionState.createNewAuction(e,t,n),this.logger.log("[AUCTION][".concat(r,"]: Running with plan: ").concat((t={auctionId:(t=e).auctionId,usePrebid:t.usePrebid,useUam:t.useUam,hbSlots:t.hbSlots.map(function(t){return t.slotDivId}),gptSlots:t.gptSlots.map(function(t){return t.slotDivId}),hbTimeout:t.hbTimeout,breakpointName:t.breakpointName},JSON.stringify(t)))),this.settings.isYandexEnabled()?(i=this.settings.getYandexBlockId())?(this.logger.log("[AUCTION][".concat(r,"]: Run Yandex with blockId ").concat(i)),window.yaContextCb.push(function(){e.gptSlots.forEach(function(t){var e=t.slotDivId,t=t.slotTemplate.id,t=Number(t.substring(7)+e.substring(e.lastIndexOf("-")+1));o.logger.log("[AUCTION][".concat(r,"][").concat(e,"]: Set pageNumber ").concat(t)),Ya.Context.AdvManager.render({renderTo:"".concat(e),blockId:i,pageNumber:t,onRender:function(){o.reporter.setStateStatus("yandex_unit_rendered")}})})})):this.logger.error("[AUCTION][".concat(r,"]: Cannot run Yandex cause yandexBlockId is not set")):(e.usePrebid&&In.pushToPrebidQue(function(){var t=o.preparePrebidRequest(r,e.hbSlots);o.startPrebidAuction(r,t,e.hbTimeout)}),e.useUam&&(n=this.prepareUamRequest(r,e.hbSlots),this.startUamAuction(r,n)),t=e.usePrebid&&!this.auctionState.getAuctionStatus(r).prebidCancelled,n=e.useUam&&!this.auctionState.getAuctionStatus(r).uamCancelled,t||n?this.setAuctionTimeout(e.hbTimeout,r):this.startGptOnlyAuction(r,s))},T.prototype.reportOnLoadEvent=function(t){t=t.slot.getSlotElementId();this.auctionState.onGptSlotLoaded(t)},T.prototype.reportSlotResponseReceived=function(t){t=t.slot.getSlotElementId();this.auctionState.onGptResponse(t)},T.prototype.reportOnRenderEndedEvent=function(t){var e=!t.isEmpty,n=t.slot.getSlotElementId(),t=(this.logger.debug("[AUCTION]: ".concat(n," render event details: ").concat(JSON.stringify(t))),this.fuseSlotRegistry.getSlot(n));t?(e?this.logger.info("[AUCTION]: Adserver responded with creative for ".concat(n)):(t={fuseSlotId:t.slotTemplate.id,fuseSlotCode:n,errorType:"MISSING_CREATIVE"},this.reporter.addSlotProblem(t),this.logger.warn("[AUCTION]: Adserver responded without creative for ".concat(n))),this.auctionState.onGptSlotRendered(n,e)):this.fuseSlotRegistry.isDeletedSlot(n)?(this.logger.info("[AUCTION]: Slot Render Ended Event fired for deleted unit ".concat(n)),this.auctionState.onGptSlotRendered(n,e)):this.logger.debug("[AUCTION]: SlotRenderEnded Event fired for non fuse units: ".concat(n,". HasCreative: ").concat(e))},T.prototype.getStateView=function(){return this.auctionState};var Qi=T;function T(t,e,n,i,o,r){this.fuseSlotRegistry=t,this.prebidGlobal=e,this.uam=n,this.logger=i,this.reporter=o,this.settings=r,this.firstPrebidRequest=!1,this.firstUamRequest=!1,this.firstPrebidResponse=!1,this.firstUamResponse=!1,this.auctionState=new Zi(i,o)}A.prototype.queueSlots=function(t){var e,n=this,i=this.getCurrentBreakpointName(),t=t.filter(function(t){return n.settings.isSlotEnabledForBreakpoint(t.slotTemplate.id,i)?t.currentlyActive?n.isScheduled(t)?(n.logger.debug("[SCHEDULER]: Skipped ".concat(t.slotDivId," because it is already scheduled")),!1):!n.isRefreshDisabled(t.slotDivId)||(n.logger.debug("[SCHEDULER]: Skipped ".concat(t.slotDivId," because it is disabled")),!1):(n.logger.info("[SCHEDULER]: Skipped ".concat(t.slotDivId," because it is hasn't activated")),!1):(n.logger.debug("[SCHEDULER]: Skipped ".concat(t.slotDivId," because no sizes mapped at the current breakpoint (").concat(i,")")),!1)});0<t.length&&(e=t.map(function(t){return t.slotDivId}),this.logger.info("[SCHEDULER]: Added ".concat(e," to auction queue")),t.forEach(function(t){return n.queuedSlots.push(t)}))},A.prototype.isScheduled=function(e){return 0<this.queuedSlots.filter(function(t){return t.slotDivId===e.slotDivId}).length},A.prototype.isTemplateScheduled=function(e){return 0<this.queuedSlots.filter(function(t){return t.slotTemplate.id===e}).length},A.prototype.isRefreshDisabled=function(e){return 0<this.disabledSlots.filter(function(t){return t===e}).length},A.prototype.purgeDeletedFromQueue=function(){var e=this;this.queuedSlots=this.queuedSlots.filter(function(t){return!e.isDeletedSlot(t.slotDivId)||(e.logger.info("[SCHEDULER]: Removed deleted slot ".concat(t.slotDivId," from queue")),!1)})},A.prototype.runAuction=function(){if(this.purgeDeletedFromQueue(),0===this.queuedSlots.length)return this.logger.log("[SCHEDULER]: Auction will not run because no slots are queued"),[];var t,e=this.getMissingAuctionBlockSlots();if(0<e.length){if(this.auctionBlockTimeoutHandle)return t=this.queuedSlots.map(function(t){return t.slotDivId}),this.logger.info("[SCHEDULER] Deferred the auction for ".concat(JSON.stringify(t)," because slots missing from the auction block: ").concat(JSON.stringify(e))),this.auctionBlockTriggered=!0,[]}else this.auctionBlockTimeoutHandle&&(this.logger.info("[SCHEDULER]: Auction block cleared, as requirements satisfied "),this.clearAuctionBlock());this.settings.isRefreshCountFromLoaded()||this.scheduleRefreshTimers();var n=this.planAuction(this.queuedSlots,this.getAuctionMaxViewports());return this.queuedSlots=this.queuedSlots.filter(function(t){return-1===n.gptSlots.indexOf(t)}),this.logger.log("[SCHEDULER]: Starting auction with ".concat(n.gptSlots.length," slots, ").concat(this.queuedSlots.length," slots remaining")),this.startAuction(n),n.gptSlots.map(function(t){return t.slotDivId})},A.prototype.forceRunAuction=function(t){var e=this.planAuction([t]);this.logger.log("[SCHEDULER][".concat(e.auctionId,"]: Forcing auction for ").concat(t.slotDivId)),this.startAuction(e)},A.prototype.disableSlotRefresh=function(e){this.disabledSlots=this.disabledSlots.filter(function(t){return t!==e}).concat(e)},A.prototype.enableSlotRefresh=function(e){this.disabledSlots=this.disabledSlots.filter(function(t){return t!==e})},A.prototype.getAuctionMaxViewports=function(){return this.isAnyAuctionExecuted()?void 0:this.settings.getMaxViewportsFirstAuction()},A.prototype.handleOnSlotOutcome=function(t,e,n){n!==qi.GPT_LOADED||this.triggeredAuctions[t]||(this.triggeredAuctions[t]=!0,0<this.queuedSlots.length&&(this.logger.debug("[SCHEDULER][".concat(t,"]: The first slot has received a render event, initiating the next auction")),this.runAuction())),n===qi.GPT_LOADED&&this.settings.isRefreshCountFromLoaded()&&this.scheduleRefreshTimer(e)},A.prototype.startAuction=function(n){var i=this;this.anyAuctionExecuted=!0,this.executeAuction(n,function(){},function(t,e){return i.handleOnSlotOutcome(n.auctionId,t,e)})},A.prototype.scheduleRefreshTimers=function(){var e=this;this.queuedSlots.forEach(function(t){e.scheduleRefreshTimer(t)})},A.prototype.scheduleRefreshTimer=function(t){this.scheduledRefresh[t.slotDivId]||(this.scheduledRefresh[t.slotDivId]=!0,this.setRefreshTimer(t))},A.prototype.getRefreshIntervals=function(){return JSON.parse(JSON.stringify(this.refreshTimers))},A.prototype.getRefreshingCodes=function(){return Object.keys(this.refreshTimers)},A.prototype.clearRefreshIntervals=function(){var e=this;Object.keys(this.refreshTimers).forEach(function(t){e.logger.debug("[REFRESH]: Clearing refresh timer for ".concat(t)),clearInterval(e.refreshTimers[t])}),this.refreshTimers={}},A.prototype.reset=function(){this.clearRefreshIntervals(),this.clearAuctionBlock(),this.refreshCounts={},this.scheduledRefresh={},this.queuedSlots=[]},A.prototype.clearPendingAuctions=function(){this.queuedSlots=[]},A.prototype.setRefreshTimer=function(t){var e,n=t.slotTemplate.attributes.refresh,i=t.slotDivId;"number"==typeof(e=n)&&e==e&&0<n?(this.logger.log("[SCHEDULER]: Setting custom refresh time of ".concat(n," seconds for ").concat(i)),this.addRefreshInterval(t,n)):0===n?this.logger.log("[SCHEDULER]: No refresh timer set for ".concat(i)):(e=this.settings.getDefaultRefreshInterval())&&0<e?(this.logger.log("[SCHEDULER]: Setting default refresh time of ".concat(e," seconds for ").concat(i)),this.addRefreshInterval(t,e)):this.logger.debug("[SCHEDULER]: No default refresh timer exists in account settings.")},A.prototype.isSkipRefreshInEdgeBrowser=function(t){this.refreshCounts[t.slotDivId]=this.refreshCounts[t.slotDivId]||0;var e=this.refreshCounts[t.slotDivId]>this.settings.getEdgeHtmlMaxAdsRefreshLimit();return(e||!this.browserWindow.document.hasFocus())&&(this.logger.log((e?'will skip refreshing ad(code: "'.concat(t.slotDivId,'") as it reached Edge browser ads refresh limit of ').concat(this.settings.getEdgeHtmlMaxAdsRefreshLimit()," at the moment - "):"will skip refreshing ad as browser page/tab is NOT active at the moment - ").concat((new Date).toISOString(),".")),!0)},A.prototype.refreshCallback=function(t){Q.isEdgeBrowser(this.browserWindow)&&this.isSkipRefreshInEdgeBrowser(t)||(this.browserWindow.document.getElementById(t.slotDivId)?t.zoneDiv&&t.isInView(this.browserWindow)?(Q.isEdgeBrowser(this.browserWindow)&&(this.refreshCounts[t.slotDivId]+=1),this.queueSlots([t]),this.runAuction()):this.logger.debug("[SCHEDULER]: Not refreshing ".concat(t.slotDivId," because it is not in view")):this.logger.warn("[AUCTION]: Could not refresh ".concat(t.slotDivId," because a div with that id was not found in the DOM")))},A.prototype.addRefreshInterval=function(t,e){var n=this;this.refreshTimers[t.slotDivId]&&(this.logger.warn("[SCHEDULER]: Refresh timer already set for ".concat(t.slotDivId)),clearInterval(this.refreshTimers[t.slotDivId])),this.refreshTimers[t.slotDivId]=setInterval(function(){n.refreshCallback(t)},1e3*e)},A.prototype.setAuctionBlock=function(t,e){var n=this;this.auctionBlockSlots=t.filter(function(t){var e=n.settings.getSlotTemplate(t);if(!e)return n.logger.warn("[SLOTS][".concat(t,"]: Excluded from next-auction slot requirement, because the slot does not exist in this tag")),!1;if(e.activateCondition)return n.logger.warn("[SLOTS][".concat(t,"]: Excluded from next-auction slot requirement, because the slot has an activation condition")),!1;e=n.getCurrentBreakpointName();return!!n.settings.isSlotEnabledForBreakpoint(t,e)||(n.logger.info("[SLOTS][".concat(t,"]: Excluded from next-auction slot requirement, because it is not enabled at the ").concat(e," breakpoint")),!1)}),0<this.auctionBlockSlots.length?(this.logger.info("[SCHEDULER]: Enabled auction block. Will not proceed until Zones with FuseIds ".concat(JSON.stringify(this.auctionBlockSlots)," are registered, or ").concat(e,"ms have elapsed")),this.auctionBlockTimeoutHandle=setTimeout(function(){n.auctionBlockTriggered?(n.logger.warn("[SCHEDULER]: Auction block timeout reached, missing: ".concat(JSON.stringify(n.getMissingAuctionBlockSlots()),". Running deferred auction")),n.clearAuctionBlock(),n.runAuction()):(0<n.getMissingAuctionBlockSlots().length&&n.logger.warn("[SCHEDULER]: Auction block timeout reached, missing: ".concat(n.getMissingAuctionBlockSlots())),n.clearAuctionBlock())},e)):this.logger.info("[SCHEDULER]: Did not enable AuctionBlock, because no (valid) slots specified")},A.prototype.getMissingAuctionBlockSlots=function(){var e=this;return this.auctionBlockSlots.filter(function(t){return!e.isTemplateScheduled(t)})},A.prototype.isAnyAuctionExecuted=function(){return this.anyAuctionExecuted},A.prototype.clearAuctionBlock=function(){this.auctionBlockSlots=[],this.auctionBlockTriggered=null,this.auctionBlockTimeoutHandle&&clearTimeout(this.auctionBlockTimeoutHandle),this.auctionBlockTimeoutHandle=null};var Ji=A;function A(t,e,n,i,o,r,s){this.logger=t,this.browserWindow=e,this.executeAuction=n,this.planAuction=i,this.isDeletedSlot=o,this.getCurrentBreakpointName=r,this.settings=s,this.refreshTimers={},this.refreshCounts={},this.scheduledRefresh={},this.disabledSlots=[],this.queuedSlots=[],this.triggeredAuctions={},this.auctionBlockSlots=[],this.auctionBlockTimeoutHandle=null,this.auctionBlockTriggered=null,this.anyAuctionExecuted=!1}var Yi="data-fuse",Ki="".concat("div","[").concat(Yi,"]"),Xi="data-fuse-reset-at",$i=(_.prototype.prepareZoneDiv=function(t,e,n,i){return this.logger.debug("[SLOTS][".concat(t,": Preparing the element")),n.setAttribute("data-fuse-code","".concat(t)),n.setAttribute("data-fuse-zone-instance","".concat(e)),n.setAttribute("data-fuse-slot","".concat(t)),n.setAttribute("data-fuse-processed-at",this.getElapsedTime().toString()),n.removeAttribute(Xi),this.document.getElementById(t)?this.logger.warn("[DOM-SCAN]: Found existing slot element with id ".concat(t)):((e=this.document.createElement("div")).setAttribute("id","".concat(t)),e.classList.add("fuse-slot"),e.style.maxWidth="inherit",this.fuseSlotFormatter.format(n,i),this.templateSettings.isYandexEnabled()&&this.fuseSlotFormatter.updateSlotForYandex(e,i),n.appendChild(e)),n},_.assignCounter=function(t,e){return e[t]||(e[t]=0),++e[t]},_.prototype.assignSlotDivId=function(t){return"fuse-slot-".concat(t,"-").concat(_.assignCounter(t,this.slotCounter))},_.prototype.assignZoneInstanceId=function(t){return"zone-instance-".concat(t,"-").concat(_.assignCounter(t,this.zoneCounter))},_.prototype.processRawElement=function(t,e){var n=t.getAttribute(Yi),i=n?this.templateSettings.getSlotTemplate(n):null;if(!n||!i)return this.logger.warn("[SLOTS]: Unknown FuseId ".concat(n)),null;var o=t.getAttribute("data-fuse-code"),r=t.getAttribute(Xi),s=null==(s=t.id)||!s.trim()||null==(s=t.id)?void 0:s.trim();if(e){if(o&&!r)return this.logger.debug("[SLOTS]: Skip ".concat(o," because it was already processed")),null;o&&r&&this.logger.debug("[SLOTS]: Processing ".concat(o," again because it has been reset"))}else o&&this.logger.warn("[SLOTS]: Processing ".concat(o," again. This is likely to be an error, but preserved for backwards compatibility"));e=this.assignSlotDivId(n),r=this.assignZoneInstanceId(n);return this.prepareZoneDiv(e,r,t,i),{slotTemplate:i,slotDivId:e,zoneDiv:t,zoneDivId:s,zoneInstanceId:r,targeting:_.extractTargeting(t)}},_.getTargetingValue=function(t){return 0<t.indexOf(",")?t.split(",").map(function(t){return t.trim()}).filter(function(t){return""!==t}):t},_.extractTargeting=function(e){var t=e.getAttributeNames().filter(function(t){return"data-targeting-key"!==t&&"data-targeting-value"!==t}).filter(function(t){return 0===t.indexOf("data-targeting-",0)}).map(function(t){return{attributeKey:t,targetingKey:t.replace("data-targeting-","").trim()}}).map(function(t){return{key:t.targetingKey,value:e.getAttribute(t.attributeKey)}}).filter(function(t){var e=t.key,t=t.value;return e&&e.length&&t&&t.length}).map(function(t){var e=t.key,t=t.value;return{key:e,value:_.getTargetingValue(t)}}),n=e.getAttribute("data-targeting-key"),i=e.getAttribute("data-targeting-value");return n&&n.length&&i&&i.length&&!t.some(function(t){return t.key===n})&&t.push({key:n,value:_.getTargetingValue(i)}),t},_.prototype.findElementWithDomId=function(t){var e=this.document.querySelectorAll("".concat("div",'[id="').concat(t,'"][').concat(Yi,"]"));return 0==e.length?this.logger.warn("[SLOTS]: No DOM element found with both id='".concat(t,"' AND a data-fuse attribute")):1<e.length&&this.logger.warn("[SLOTS]: Multiple DOM elements found with id '".concat(t,"'")),e},_.prototype.findAllFuseElements=function(){return this.document.querySelectorAll(Ki)},_.prototype.findElementsWithTemplateId=function(t){return this.document.querySelectorAll("".concat("div","[").concat(Yi,'="').concat(t,'"]'))},_.prototype.processRawElements=function(t,e){var n=this,i=[];return t.forEach(function(t){t=n.processRawElement(t,e);t&&i.push(t)}),i},_.prototype.processSlots=function(t){var e=this.findAllFuseElements();return this.processRawElements(e,t)},_.prototype.processZoneWithDivId=function(t,e){t=this.findElementWithDomId(t),t=this.processRawElements(t,e);return t[t.length-1]},_.prototype.processLastSlotWithFuseId=function(t,e){t=this.findElementsWithTemplateId(t),t=this.processRawElements(t,e);return t[t.length-1]},_.prototype.processSlotsWithFuseId=function(t,e){t=this.findElementsWithTemplateId(t);return this.processRawElements(t,e)},_);function _(t,e,n,i,o){this.logger=t,this.document=e,this.templateSettings=n,this.fuseSlotFormatter=i,this.getElapsedTime=o,this.slotCounter={},this.zoneCounter={}}eo.prototype.logContext=function(t){return"[SLOT-FORMAT][".concat(t.id,"]:")},eo.prototype.hasOverflow=function(t,n,i){for(var o=this,r=t.parentElement,s=["hidden","scroll","auto"],e=["overflow","overflow-x","overflow-y"];r;)e.forEach(function(t){var e=o.viewportInfo.browserWindow.getComputedStyle(r)[t];if(u(e)&&-1!==s.indexOf(e)){if(!i)return o.logger.debug("".concat(o.logContext(n)," Miniscroller was not applied. ").concat(t,' on "').concat(r.id," ").concat(r.className,'"')),!0;r.style[t]="visible",o.logger.debug("".concat(o.logContext(n)," Force miniscroller. Update ").concat(t,' on "').concat(r.id," ").concat(r.className,'"'))}}),r=r.parentElement;return!1},eo.prototype.hasHeight=function(t,e,n){var i=t,o=this.viewportInfo.browserWindow.getComputedStyle(t),r=o.height,o=o.minHeight;if(this.logger.debug("".concat(this.logContext(e),' applying miniscroller on element with height "').concat(r,'" min-height: "').concat(o,'"')),-1===["0px","auto"].indexOf(r)){if(!n)return this.logger.debug("".concat(this.logContext(e)," Miniscroller was not applied because of height ").concat(r,' already set for element "').concat(t.id,'"')),!0;this.logger.debug("".concat(this.logContext(e),' Force miniscroller. Update height on "').concat(i.className,'"'))}return!1},eo.prototype.format=function(t,e){var n=e.attributes;!this.templateSettings.isMiniScrollersEnabled()||!1===n.miniscroller||n.sticky||n.interscroller||n.interstitial||n.scrollToStick||this.hasHeight(t,e)||this.hasOverflow(t,e)||(this.logger.debug("".concat(this.logContext(e),' Update slot element "').concat(t.id,'" to miniscroller')),this.updateSlotElementToMiniScroller(t,e))},eo.prototype.updateSlotElementToMiniScroller=function(t,e){var n=this.viewportInfo.getCurrentBreakpoint().name,e=(t.classList.add("fuse-slot-mini-scroller"),this.templateSettings.maxSlotHeightForBreakpoint(e,n));t.style.minHeight="".concat(e,"px")},eo.prototype.updateSlotForYandex=function(t,e){var n=this.viewportInfo.getCurrentBreakpoint().name,e=null==(e=e.sizeMapping)?void 0:e[n],i=0,o=0;e&&(e.forEach(function(t){"fluid"!==t&&(Number(t[0])>o&&(o=Number(t[0])),Number(t[1])>i&&(i=Number(t[1])))}),t.style.width="".concat(o,"px"),t.style.height="".concat(i,"px"),t.style.margin="auto")};var to=eo;function eo(t,e,n){this.logger=t,this.templateSettings=e,this.viewportInfo=n}var no=this&&this.__assign||function(){return(no=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},io=(P.prototype.getElements=function(){var e=this,n={};return Object.keys(this.REGISTERED_SLOTS).forEach(function(t){t=e.REGISTERED_SLOTS[t];n[t.slotDivId]=t.zoneDiv}),n},P.prototype.getSlotTemplates=function(){var e=this,n={};return Object.keys(this.REGISTERED_SLOTS).forEach(function(t){t=e.REGISTERED_SLOTS[t];n[t.slotDivId]=t.slotTemplate}),n},P.prototype.getSlotsForTemplateId=function(e){var n=this;return Object.keys(this.REGISTERED_SLOTS).filter(function(t){return n.REGISTERED_SLOTS[t].slotTemplate.id===e}).map(function(t){return n.REGISTERED_SLOTS[t]})},P.prototype.getActiveSlots=function(){var e=this;return Object.keys(this.REGISTERED_SLOTS).filter(function(t){return e.REGISTERED_SLOTS[t].currentlyActive}).map(function(t){return e.REGISTERED_SLOTS[t]})},P.prototype.getSlotInitObservable=function(){return this.slotInitialised},P.prototype.getSlotsInitObservable=function(){return this.slotsInitialised},P.prototype.isInDom=function(t){return u(window.document.getElementById(t))},P.prototype.isDeletedSlot=function(t){return-1!==this.DELETED_FUSE_DIVS.indexOf(t)},P.prototype.filterUndeleted=function(t,n){var i=this;return t.filter(function(t){var e=!i.isDeletedSlot(t);return!e&&n&&n(t),e})},P.prototype.reset=function(){var e=this,n=(Object.keys(this.REGISTERED_SLOTS).forEach(function(t){e.isDeletedSlot(t)&&e.logger.log("[EVENT]: resetSlots() unit already deleted ".concat(t)),e.DELETED_FUSE_DIVS.push(t)}),this.getElements());Object.keys(n).forEach(function(t){n[t].setAttribute(Xi,e.reporter.getElapsedTime().toString())}),Object.keys(this.SLOT_ACTIVATOR).forEach(function(t){e.SLOT_ACTIVATOR[t].destroy()}),this.REGISTERED_SLOTS={},this.SLOT_ACTIVATOR={},this.clearFuseSkins()},P.prototype.registeredSlotConfig=function(e,t,n,i,o){var r=this;return{slotDivId:e,zoneDiv:i,zoneDivId:o,zoneInstanceId:t,slotTemplate:n,isInView:function(t){t=n.attributes.interscroller?t.document.querySelector(".publift-widget-".concat(n.id,"-container")):t.document.getElementById(e);return jt(r.viewportInfo.getViewportStatus(),t,50,0)}}},P.prototype.registerActiveSlot=function(t,e){t.currentlyActive=!0,this.enablePartners(t,e),this.events.onZoneEvent.emit({zoneTemplateId:t.slotTemplate.id,zoneDivId:t.zoneDivId,zoneEventType:"registered",instanceId:t.zoneInstanceId,status:"active"})},P.prototype.registerInactiveSlot=function(t,e){this.SLOT_ACTIVATOR[t.slotDivId]=e,this.events.onZoneEvent.emit({zoneTemplateId:t.slotTemplate.id,zoneDivId:t.zoneDivId,zoneEventType:"registered",instanceId:t.zoneInstanceId,status:"inactive"})},P.prototype.activateInactiveSlot=function(t,e,n){var i;this.REGISTERED_SLOTS[t]&&!0===this.REGISTERED_SLOTS[t].currentlyActive?this.logger.warn("[SLOTS][".concat(t,"]: Skipped activation because the slot was already activated")):this.isInDom(t)?(i=this.REGISTERED_SLOTS[t],this.SLOT_ACTIVATOR[t].destroy(),i.currentlyActive=!0,this.enablePartners(i,e),this.events.onZoneEvent.emit({zoneTemplateId:i.slotTemplate.id,zoneDivId:i.zoneDivId,zoneEventType:"activated",instanceId:i.zoneInstanceId}),n([i])):(this.logger.warn("[SLOTS][".concat(t,"]: Skipped activation because the slot was removed from the DOM")),this.deleteSlot(t))},P.prototype.enablePartners=function(t,e){this.enableGptAsync(t,e),this.settings.isHeaderBiddingSlot(t.slotTemplate)?this.enablePrebidAsync(t):this.logger.debug("[SLOTS]: Skip prebid registration for ".concat(t.slotDivId," because headerbidding not enabled"))},P.prototype.enablePrebidAsync=function(t){var e=this;In.pushToPrebidQue(function(){e.isDeletedSlot(t.slotDivId)?e.logger.log("[SLOTS]: Skip prebid registration for deleted unit ".concat(t.slotDivId)):In.setPrebidAdUnits(t)})},P.prototype.enableGptAsync=function(e,n){var i=this;y(function(){var t;i.isDeletedSlot(e.slotDivId)?i.logger.log("[SLOTS]: Skip registration for deleted unit ".concat(e.slotDivId)):(t=Te(e,n))&&(i.gptSlotRegistry.add(e.slotTemplate.id,t),t=e.slotDivId,b.debug("[GPT]: googletag.display(".concat(t,")")),d.display(t))})},P.prototype.deleteSlot=function(t){this.logger.debug("[SLOTS][".concat(t,"]: Deleting slot")),this.DELETED_FUSE_DIVS.push(t),delete this.REGISTERED_SLOTS[t],this.SLOT_ACTIVATOR[t].destroy(),delete this.SLOT_ACTIVATOR[t]},P.prototype.getSlot=function(t){return this.REGISTERED_SLOTS[t]},P.prototype.getSlots=function(t){var e=this,n=[];return t.forEach(function(t){t=e.getSlot(t);t&&n.push(t)}),n},P.prototype.buildActivator=function(t,e,n,i,o){var r=this;return this.conditionFactory.buildActivator(e,t,n,function(){return r.activateInactiveSlot(t,i,o)})},P.prototype.registerFuseSlot=function(t,e,n,i,o,r,s,a,c){n=no(no({},this.registeredSlotConfig(t,n,o,e,i)),{currentlyActive:!1,storedAt:this.reporter.getElapsedTime(),breakpoint:this.viewportInfo.getCurrentBreakpoint().name});return this.REGISTERED_SLOTS[t]=n,s?(this.logger.log("[SLOTS][".concat(t,"]: Registering as active because it is forced")),this.registerActiveSlot(n,r)):o.activateCondition?(e=this.buildActivator(t,o.activateCondition,a,r,c)).checkCondition()?(this.logger.log("[SLOTS][".concat(t,"]: Registering as active because conditions already satisfied")),this.registerActiveSlot(n,r)):(this.logger.log("[SLOTS][".concat(t,"]: Registering as inactive and enabling triggers")),this.registerInactiveSlot(n,e),e.enableTriggers()):(this.logger.log("[SLOTS][".concat(t,"]: Registering as active because no conditions defined")),this.registerActiveSlot(n,r)),this.slotInitialised.emit({}),n},P.prototype.register=function(t,e,n,i){var o=this,t=t.map(function(t){return o.registerFuseSlot(t.slotDivId,t.zoneDiv,t.zoneInstanceId,t.zoneDivId,t.slotTemplate,t.targeting,n,e,i)});return this.logger.debug("[SLOTS]: Registered ".concat(t.length," slots")),this.slotsInitialised.emit({}),t},P.prototype.clearFuseSkins=function(){this.logger.debug("[DOM]: Clearing fuse skins");for(var t=this.browserWindow.document.querySelectorAll("div.fuse-custom-skin"),e=0;e<t.length;e++)t[e].parentNode.removeChild(t[e])},P);function P(t,e,n,i,o,r,s,a){this.logger=t,this.reporter=e,this.browserWindow=n,this.gptSlotRegistry=i,this.settings=o,this.conditionFactory=r,this.viewportInfo=s,this.events=a,this.DELETED_FUSE_DIVS=[],this.REGISTERED_SLOTS={},this.SLOT_ACTIVATOR={},this.slotInitialised=new ct(this.logger,"onSlotCreated"),this.slotsInitialised=new ct(this.logger,"onSlotsInitialised")}R.prototype.registerAndQueue=function(t,e,n){t=this.domProcessor.processSlots(t),t=this.registerSlots(t,n,e),n=t.filter(function(t){return t.currentlyActive});return this.auctionScheduler.queueSlots(n),t},R.prototype.registerAndRunAuction=function(t,e,n){t=this.registerAndQueue(t,e,n);return this.runAuction(),t},R.prototype.registerZoneAndQueue=function(t,e,n,i){t=this.domProcessor.processZoneWithDivId(t,e);if(!t)return null;e=this.registerSlots([t],i,n)[0];return null!=e&&e.currentlyActive&&this.auctionScheduler.queueSlots([e]),e},R.prototype.activateZone=function(t){this.zoneRegistry.activateZone(t)},R.prototype.registerAndQueueLastSlotWithFuseId=function(t,e,n,i){t=this.domProcessor.processLastSlotWithFuseId(t,e);if(t)return e=this.registerSlots([t],i,n)[0],e&&e.currentlyActive&&this.auctionScheduler.queueSlots([e]),e},R.prototype.registerSlots=function(t,e,n){var i=this;return t.map(function(t){i.zoneRegistry.register(t)}),this.fuseSlotRegistry.register(t,e,n,this.runAuctionFn)},R.prototype.registerAndQueueWithFuseId=function(t,e,n,i){t=this.domProcessor.processSlotsWithFuseId(t,e),e=this.registerSlots(t,i,n),t=e.filter(function(t){return t.currentlyActive});return this.auctionScheduler.queueSlots(t),e},R.prototype.runAuction=function(){return this.isTagInitialised()?this.auctionScheduler.runAuction():(this.logger.info("[CONTROLLER] Deferred the auction start until the tag is initialised"),!1)},R.prototype.forceRunAuction=function(t){var e=this.fuseSlotRegistry.getSlot(t);e?this.auctionScheduler.forceRunAuction(e):this.logger.warn("[CONTROLLER]: Could not force auction because slot ".concat(t," not found"))},R.prototype.runAuctionAllActiveSlots=function(){this.auctionScheduler.queueSlots(this.fuseSlotRegistry.getActiveSlots()),this.runAuction()},R.prototype.reset=function(){this.logger.log("[CONTROLLER]: resetSlots()"),this.fuseSlotRegistry.reset(),this.auctionScheduler.reset(),this.zoneRegistry.reset()},R.prototype.clearRefreshIntervals=function(){this.auctionScheduler.clearRefreshIntervals()},R.prototype.getRefreshIntervals=function(){return this.auctionScheduler.getRefreshIntervals()},R.prototype.configureResponsive=function(){var e=this;this.onBreakpointChange.subscribe(function(t){t=t.name,e.logger.log("[CONTROLLER]: Breakpoint changed to ".concat(t,". Cleared pending auctions, refreshes, next-auction requirements. All active slots will re-auction now.")),e.auctionScheduler.clearPendingAuctions(),e.auctionScheduler.clearAuctionBlock(),e.auctionScheduler.clearRefreshIntervals(),t=e.fuseSlotRegistry.getActiveSlots();e.auctionScheduler.queueSlots(t),e.auctionScheduler.runAuction()})},R.prototype.loadSlots=function(t,e,n){t?(n(),this.registerAndQueue(!1,!1,e),this.runAuction()):(this.logger.warn("[CONTROLLER]: loadSlots() called during initialisation. Translating call to registerSlots() to avoid reset"),this.registerAndRunAuction(!0,!1,e))};var oo=R;function R(t,e,n,i,o,r,s,a){var c=this;this.fuseSlotRegistry=t,this.zoneRegistry=e,this.logger=n,this.auctionScheduler=i,this.settings=o,this.domProcessor=r,this.isTagInitialised=s,this.onBreakpointChange=a,this.runAuctionFn=function(t){c.auctionScheduler.queueSlots(t),c.runAuction()}}so.prototype.register=function(t){var e=t.zoneInstanceId;if(!this.REGISTERED_ZONES[e]){var n=t.zoneDivId?this.findByDivId(t.zoneDivId):void 0;if(n){var i=n.zoneDiv,n=n.zoneInstanceId;if(n===e)return void this.logger.error("[ZONE][".concat(n,"]: Ignoring unexpected re-registration"));this.logger.warn("[ZONE][".concat(n,"]: Div ").concat(i.id," replaced in DOM without pageInit(). Registering ").concat(e)),this.DELETED_ZONES.push(n),delete this.REGISTERED_ZONES[n],delete this.MANUAL_ACTIVATE_API[n]}this.logger.info("[ZONE][".concat(e,"]: Registered with DivId ").concat(t.zoneDiv.id));i={zoneInstanceId:e,zoneDiv:t.zoneDiv,zoneDivId:t.zoneDivId,zoneTemplateId:t.slotTemplate.id};return this.REGISTERED_ZONES[e]=i}this.logger.error("[ZONE][".concat(e,"]: Already registered"))},so.prototype.isDeletedZone=function(t){return-1!==this.DELETED_ZONES.indexOf(t)},so.prototype.findByDivId=function(e){var n=this;return Object.keys(this.REGISTERED_ZONES).map(function(t){return n.REGISTERED_ZONES[t]}).filter(function(t){return t.zoneDivId==e}).shift()},so.prototype.activateZone=function(t){var e=this.findByDivId(t);if(!e)return this.logger.error("[ZONE][".concat(t,"]: Unknown zone")),!1;t=e.zoneInstanceId;return!this.MANUAL_ACTIVATE_API[t]&&(this.MANUAL_ACTIVATE_API[t]=!0,this.zoneEventEmitter.emit({zoneTemplateId:e.zoneTemplateId,zoneDivId:e.zoneDivId,zoneEventType:"activate_zone_api",instanceId:e.zoneInstanceId}),!0)},so.prototype.isManuallyActivated=function(t){var e;return this.REGISTERED_ZONES[t]?null!=(e=this.MANUAL_ACTIVATE_API[t])&&e:(this.logger.error("[ZONE][".concat(t,"]: Unknown zone")),!1)},so.prototype.getRegisteredZones=function(){var e=this;return Object.keys(this.REGISTERED_ZONES).map(function(t){return e.REGISTERED_ZONES[t]})},so.prototype.reset=function(){var e=this;Object.keys(this.REGISTERED_ZONES).forEach(function(t){e.isDeletedZone(t)?e.logger.debug("[EVENT]: resetSlots() unit already deleted ".concat(t)):e.DELETED_ZONES.push(t)}),this.MANUAL_ACTIVATE_API={},this.REGISTERED_ZONES={}};var ro=so;function so(t,e){this.logger=t,this.zoneEventEmitter=e,this.DELETED_ZONES=[],this.REGISTERED_ZONES={},this.MANUAL_ACTIVATE_API={}}function ao(){}ao.prototype.getAuctionExecutor=function(){return this.auctionExecutor||(this.auctionExecutor=new Qi(this.getFuseSlotRegistry(),ln.getPrebidGlobal(),Wi.getUam(),p.getLogger(),a.getReporter(),f)),this.auctionExecutor},ao.prototype.getFuseSlotRegistry=function(){return this.fuseSlotRegistry||(this.fuseSlotRegistry=new io(p.getLogger(),a.getReporter(),p.getBrowserWindowObject(),Cn.getGptSlotRegistry(),f,Ci.getSlotConditionFactory(),l.getViewportInfo(),h)),this.fuseSlotRegistry},ao.prototype.getZoneRegistry=function(){return this.zoneRegistry||(this.zoneRegistry=new ro(p.getLogger(),h.onZoneEvent)),this.zoneRegistry},ao.prototype.getAuctionScheduler=function(){var i=this;return this.auctionScheduler||(this.auctionScheduler=new Ji(p.getLogger(),p.getBrowserWindowObject(),function(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return(t=i.getAuctionExecutor()).executeAuction.apply(t,e)},function(t,e){return i.getAuctionPlanner().plan(t,e)},function(t){return i.getFuseSlotRegistry().isDeletedSlot(t)},function(){return l.getViewportInfo().getCurrentBreakpoint().name},f)),this.auctionScheduler},ao.prototype.getAuctionPlanner=function(){return this.auctionPlanner||(this.auctionPlanner=new zi(p.getLogger(),f,l.getViewportInfo(),function(){return Pn.getInitManager().isLowDwellPage()},a.getComponentStatusStore())),this.auctionPlanner},ao.prototype.getController=function(){return this.controller||(this.controller=new oo(this.getFuseSlotRegistry(),this.getZoneRegistry(),p.getLogger(),this.getAuctionScheduler(),f,this.getDomProcessor(),function(){return Pn.getInitManager().isTagInitialised()},h.onBreakpointChanged)),this.controller},ao.prototype.getDomProcessor=function(){return this.domProcessor||(this.domProcessor=new $i(p.getLogger(),p.getBrowserWindowObject().document,f,this.getFuseSlotFormatter(),function(){return a.getReporter().getElapsedTime()})),this.domProcessor},ao.prototype.getFuseSlotFormatter=function(){return this.fuseSlotFormatter||(this.fuseSlotFormatter=new to(p.getLogger(),f,l.getViewportInfo())),this.fuseSlotFormatter};var co=new ao,uo=(Object.defineProperty(lo.prototype,"value",{get:function(){return this.f},enumerable:!1,configurable:!0}),lo.prototype.asSupplier=function(){var t=this;return function(){return t.f}},lo);function lo(t,e){var n=this;this.f=e,t.immediateOrOnce(function(t){return n.f=t})}function go(t,e){if(t&&e)return t=new URL(t),e=new URL(e),t.hash="",e.hash="",t.toString()==e.toString()}ho.prototype.reset=function(){return this.logger.info("[PAGE]: Resetting all page state"),this.resetPageFn()},ho.prototype.handlePageInitCall=function(t,e,n){this.logger.info("[PAGE]: pageInit('".concat(t,"', ").concat(e,", ").concat(JSON.stringify(n)));var i,o=null===this.lastPageInitUrl,r=u(this.tagInitOnce.value);if(o)if(r){if(go(t,this.initialUrl))return void this.logger.warn("[PAGE]: Ignored pageInit(), because URL unchanged since tag init");this.logger.info("[PAGE]: First pageInit() call, and URL changed since tag init. Resetting."),this.reset(),i=!0}else i=!1;else{if(go(t,this.lastPageInitUrl))return void this.logger.warn("[PAGE]: Ignored pageInit(), because URL unchanged since last pageInit call");this.logger.info("[PAGE]: pageInit() called, and the URL has changed. Resetting."),i=!0,this.reset()}this.lastPageInitUrl=t,null!=n&&n.pageTargets&&this.setPageTargeting(null==n?void 0:n.pageTargets),null!=n&&n.blockingFuseIds&&this.setBlock(null!=(o=null==n?void 0:n.blockingTimeout)?o:2e3,n.blockingFuseIds,i,e),r&&this.emitPageInit(t,!1)},ho.prototype.isPageInitCalled=function(){return u(this.lastPageInitUrl)},ho.prototype.isLowDwellUrl=function(e){return 0<this.lowDwellPages.filter(function(t){t=e.match(t);return t&&0<t.length}).length},ho.prototype.emitPageInit=function(t,e){e={url:t,isFirstPageInit:e,isLowDwellPage:this.isLowDwellUrl(t),breakpoint:this.currentBreakpoint().name};this.pageInitEmitter.emit(e)},ho.prototype.setBlock=function(t,e,n,i){n=n?t:t-i;n<=0?this.logger.info("[PAGE][pageInit]: Skipped setting auction block, because there is no time left on the timeout"):(t=e.map(function(t){return"".concat(t)}),this.setAuctionBlockFn(t,n))};var po=ho;function ho(t,e,n,i,o,r,s,a,c){var u=this;this.logger=t,this.initialUrl=e,this.resetPageFn=n,this.setAuctionBlockFn=i,this.setPageTargeting=o,this.pageInitEmitter=r,this.currentBreakpoint=s,this.lowDwellPages=c,this.lastPageInitUrl=null,this.tagInitOnce=new uo(a),a.immediateOrOnce(function(t){u.emitPageInit(t.tagInitUrl,!0)})}var fo=!1,bo=p.getLogger(),mo=function(){return p.getBrowserWindowObject().fusetag.que},yo=function(){return mo().length},So=function(){return mo().push=function(t){if("function"==typeof t)try{t.call()}catch(t){bo.error("Error processing command :",t.message,t.stack)}else bo.error("Commands written into fusetag.que.push must be wrapped in a function")}};Io.prototype.getCurrentBreakpointName=function(){return this.viewportInfo.getCurrentBreakpoint().name},Io.prototype.getWindow=function(){return this.viewportInfo.browserWindow},Io.prototype.registerAll=function(){this.logger.debug("[APIV3]: registerAll() started");var t=this.slotsController.registerAndRunAuction(!0,!1,this);this.logger.debug("[APIV3]: registerAll() finished, ".concat(t.length," slots found"))},Io.prototype.processNewSlots=function(){this.registerAll()},Io.prototype.registerZone=function(t){this.logger.debug("[APIV3]: registerZone('".concat(t,"') started"));t=this.slotsController.registerZoneAndQueue(t,!0,!1,this);return t&&this.slotsController.runAuction(),t},Io.prototype.queueZone=function(t){return this.logger.debug("[APIV3]: queueZone('".concat(t,"') started")),this.slotsController.registerZoneAndQueue(t,!0,!1,this)},Io.prototype.runAuction=function(){return this.logger.debug("[APIV3]: runAuction() started"),this.slotsController.runAuction()},Io.prototype.disableRefreshByZone=function(t){return this.auctionScheduler.disableSlotRefresh(t)},Io.prototype.enableRefreshByZone=function(t){return this.auctionScheduler.enableSlotRefresh(t)},Io.prototype.getSlotsForTemplateId=function(t){return this.slotRegistry.getSlotsForTemplateId(t)};var vo=Io;function Io(t,e,n,i,o,r,s,a,c,u){this.logger=t,this.settingsGlobal=e,this.slotsController=n,this.slotRegistry=i,this.zoneRegistry=o,this.auctionScheduler=r,this.insertConditionFactory=s,this.slotConditionFactory=a,this.events=c,this.viewportInfo=u,this.settings=new Eo(this.settingsGlobal)}wo.prototype.getSlotTemplate=function(t){return this.settings.getSlotTemplate(t)},wo.prototype.setDisableWidgetRenderer=function(t){this.settings.getV2CompatOverrides().disableWidgetsRenderer=t};var Eo=wo;function wo(t){this.settings=t}function Co(){}Co.prototype.getApiV3=function(){return this.apiV3||(this.apiV3=new vo(p.getLogger(),f,co.getController(),co.getFuseSlotRegistry(),co.getZoneRegistry(),co.getAuctionScheduler(),Ci.getInsertConditionFactory(),Ci.getSlotConditionFactory(),h,l.getViewportInfo())),this.apiV3},Co.prototype.getPageManager=function(){var t=this;return this.pageManager||(this.pageManager=new po(p.getLogger(),p.getBrowserWindowObject().location.href,function(){return t.resetPage()},function(){return co.getAuctionScheduler().isAnyAuctionExecuted()},function(t){t.forEach(function(t){return kn(t.key,t.value)})},h.onPageInit,l.getViewportInfo().breakpointSupplier(),h.onTagInitComplete,f.getLowDwellPages())),this.pageManager},Co.prototype.resetPage=function(){Cn.getGptSlotRegistry().purgeAll(),In.reset(),co.getController().reset(),On(),bo.debug("[QUEUE]: Cleared fuse queue with ".concat(yo()," remaining items")),mo().splice(0,mo().length),Re(),de={},le={}};var To=new Co,Ao=(_o.prototype.initInterstitial=function(){var t,e,n=this;this.hasInterstitial?this.logger.log("[INTERSTITIAL]: Already present"):(this.logger.info("[INTERSTITIAL]: Initialising"),null!=(t=this.settings.getFuseSlots().find(function(t){return t.attributes&&!0===t.attributes.interstitial}))&&t.injectConditionConfig?(e=this.insertFactory.buildActivator(t.injectConditionConfig,t.id,this.apiV3,function(){n.setInterstitialSlot(t)})).checkCondition()?this.setInterstitialSlot(t):e.enableTriggers():t&&this.setInterstitialSlot(t))},_o.prototype.setInterstitialSlot=function(t){(t=t)&&((t=d.defineOutOfPageSlot(t.slot,d.enums.OutOfPageFormat.INTERSTITIAL))?(t.addService(d.pubads()),d.enableServices(),d.display(t),Pe(),d.pubads().refresh([t])):b.warn("setInterstitialSlot(): googletag.defineOutOfPageSlot returned undefined")),this.hasInterstitial=!0},_o);function _o(t,e,n,i){this.logger=t,this.settings=e,this.insertFactory=n,this.apiV3=i,this.hasInterstitial=!1}Ro.prototype.getStatuses=function(){return this.statuses},Ro.prototype.start=function(t,e){var n=this;!(e=void 0===e?!1:e)&&this.statuses.length||(this.logger.debug("[WIDGETS][CHECKER] Start to check slots"),this.statuses=t.filter(function(t){var e;return(null==(e=t.dynamicAttributes)?void 0:e.selector)||(null==(e=t.interscrollerAttributes)?void 0:e.selector)}).map(function(t){var e=(null==(e=t.dynamicAttributes)?void 0:e.selector)||(null==(e=t.interscrollerAttributes)?void 0:e.selector);return{slot:t,selector:e,countSelector:n.countSelector(e),countSlot:n.countSlot(t.id)}}),this.statuses.length&&(this.checkInterval=setInterval(function(){return n.check()},100)))},Ro.prototype.stop=function(){this.checkInterval&&clearInterval(this.checkInterval),this.statuses=[]},Ro.prototype.check=function(){var i=this;this.statuses.forEach(function(t){var e=i.countSelector(t.selector),n=i.countSlot(t.slot.id);t.countSelector===e&&t.countSlot===n||(i.logger.debug("[WIDGETS][".concat(t.slot.id,'] Injecting by selector "').concat(t.selector,'" change: selectors ').concat(e," slots ").concat(n)),i.widgetsRenderer.injectWidget(t.slot),t.countSelector=i.countSelector(t.selector),t.countSlot=i.countSlot(t.slot.id))})},Ro.prototype.countSelector=function(t){return document.querySelectorAll(t).length},Ro.prototype.countSlot=function(t){return document.querySelectorAll('[data-fuse="'.concat(t,'"]')).length};var Po=Ro;function Ro(t,e){this.logger=t,this.widgetsRenderer=e,this.checkInterval=null,this.statuses=[]}Do.prototype.getZoneDivId=function(){return"fuse-injected-".concat(this.slot.id,"-").concat(++this.incrementalCounter)},Do.prototype.createSlotElement=function(){return this.toHTML('<div id="'.concat(this.getZoneDivId(),'" data-fuse="').concat(this.slot.id,'" data-fuse-injected-at="').concat((new Date).getTime(),'" class="fuse-slot-').concat(this.type,'"></div>'))},Do.prototype.toHTML=function(t){var e=document.createElement("div");return e.innerHTML=t,e.firstElementChild},Do.prototype.getFuseSlotHeight=function(){var t=this.viewportInfo.getCurrentBreakpoint().name,e=this.slot.sizeMapping,e=null==e?void 0:e[t],t=e?e.map(function(t){return Number(t[1])}):[];return t.length?Math.max.apply(Math,t):0},Do.prototype.getFuseSlotWidth=function(){var t=this.viewportInfo.getCurrentBreakpoint().name,e=this.slot.sizeMapping,e=null==e?void 0:e[t],t=e?e.map(function(t){return Number(t[0])}):[];return t.length?Math.max.apply(Math,t):0},Do.prototype.getLogContext=function(){return"[".concat(this.type,"][").concat(this.slot.id,"]:")},Do.prototype.getClassName=function(){return"publift-widget-".concat(this.slot.id)},Do.prototype.getContainerElement=function(){return document.querySelector(".".concat(this.getClassName(),"-container"))},Do.prototype.getStylesElement=function(){return document.querySelector("#".concat(this.getClassName(),"-styles"))},Do.prototype.getWidgetElement=function(){return document.querySelector(".".concat(this.getClassName()))};n=Do;function Do(t,e,n){this.slot=t,this.logger=e,this.viewportInfo=n,this.incrementalCounter=0}var Oo,ko,xo=this&&this.__extends||(Oo=function(t,e){return(Oo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}Oo(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),Lo=this&&this.__assign||function(){return(Lo=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},No=(xo(D,ko=n),D.prototype.createWidget=function(t){var e=this.getClassName();return this.toHTML('\n<div class="'.concat(e,'-container closed" style="display: ').concat(0===t?"none":"block",'">\n<div class="').concat(e,'-container-background">\n</div>\n  <div class="').concat(e,'-button">\n    <div></div>\n    <div></div>\n  </div>\n  <div class="').concat(e,'">\n  </div>\n</div>\n'))},D.prototype.getHideAtElement=function(){var t=this.getAttributes().hideSelector;return t?document.querySelector(t):null},D.prototype.getFixedElement=function(){var t=this.getAttributes().fixedSelector;return t?document.querySelector(t):null},D.prototype.getFixedClass=function(){return"".concat(this.getClassName(),"-fixed")},D.prototype.getWidgetCloseButtonElement=function(){return document.querySelector(".".concat(this.getClassName(),"-button"))},D.prototype.makeAttributes=function(){var t=Lo({bgColor:"#EFEFEF",bgOpacity:.7,allowClose:!1,buttonColor:"#313131",barColor:"#EFEFEF",borderWidth:"0px",zIndex:2147483645,compact:!1},this.slot.stickyAttributes);return t.compact&&(t.bgOpacity=1,t.bgColor=t.barColor),t},D.prototype.addContent=function(t,e){var n=this,i=this.getClassName(),o=t.querySelector(".".concat(i)),r=this.createSlotElement(),o=(o.appendChild(r),t.querySelector(".".concat(i,"-button")).addEventListener("click",function(){t.classList.contains("closed")?n.onShow():n.onClose(),clearInterval(n.hideAtElementInterval)}),document.querySelector("body"));return o.insertAdjacentElement("beforeend",e),o.insertAdjacentElement("beforeend",t),r},D.prototype.getButtonStyles=function(t,e,n,i,o){return t?e?"border-radius: 0 0 2px 2px; top: ".concat(n,"px;"):"border-radius: 2px 2px 0 0; top: -20px;":e?"border-radius: 2px 2px 0 0; top: ".concat(i-20+o,"px;"):"border-radius: 0 0 2px 2px; top: 0px;"},D.prototype.getFixedSelectorStyles=function(t,e,n,i,o){return e?".".concat(t,"-fixed {\n  ").concat(n?"top":"bottom"," : ").concat(i?o:0,"px;\n}\n").concat(e," {\n  transition: ").concat(n?"top":"bottom"," .3s linear;\n}"):""},D.prototype.createStyles=function(){var t=this.getAttributes(),e=t.zIndex,n=t.compact,i=t.isTop,o=t.isButtonOutside,r=t.bgColor,s=t.bgOpacity,a=t.barColor,c=t.allowClose,u=t.allowReopen,l=t.buttonColor,d=t.fixedSelector,t=t.borderWidth,g=this.getFuseSlotHeight(),p=this.getContainerBordersSize(),h=this.getContainerBorderSize(),f=g+p,b=this.getFuseSlotWidth(),p=b+p,m=u&&o?h:0,y=this.getClassName();return this.toHTML('\n<style id="'.concat(y,'-styles">\n.').concat(y,"-container {\n  z-index: ").concat(e,";\n  position: fixed;\n  ").concat(i?"top: 0":"bottom: 0",";\n  width: ").concat(n?p+"px":"100%",";\n  height: ").concat(f,"px;\n  transition: transform .3s linear, height .3s linear;\n  ").concat(o?"":"overflow: hidden;","\n  visibility: hidden;\n  ").concat(n?"left: 50%; transform: translateX(-50%);":"left: 0;","\n}\n.").concat(y,"-container-background {\n  background-color: ").concat(r,";\n  opacity: ").concat(s,";\n  position: absolute;\n  width: 100%;\n  height: 100%;\n  z-index: -1;\n}\n\n.").concat(y,"-button {\n  width: 40px;\n  margin-left: 2px;\n  height: 20px;\n  background-color: ").concat(a,";\n  flex-direction: row;\n  justify-content: center;\n  align-items: center;\n  position: absolute;\n  display: ").concat(c?"flex":"none",";\n  transition: top .3s linear;\n  ").concat(this.getButtonStyles(o,i,f,g,h),"\n}\n.").concat(y,"-button :first-child, .").concat(y,"-button :last-child  {\n  background-color: ").concat(l,";\n  width: 13px;\n  height: 3px;\n  border-radius: 2px;\n}\n.").concat(y,"-button :first-child {\n  transform: rotate(").concat(i?"-":"","30deg) translateX(2px);\n}\n.").concat(y,"-button :last-child {\n  transform: rotate(").concat(i?"":"-","30deg) translateX(-2px);\n}\n.").concat(y," {\n  width: ").concat(n?b+"px":"100%",";\n  height: ").concat(g,"px;\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  transition: transform .3s linear, height .3s linear;\n  border").concat(n?"":i?"-bottom":"-top",": ").concat(t," solid ").concat(a,";\n}\n.").concat(y,"-container.closed {\n  ").concat(i?"transform: translateY(-".concat(f-m,"px)").concat(n?" TranslateX(-50%)":"",";"):"height: "+m+"px;","\n}\n.").concat(y,"-container.closed .").concat(y,"-button {\n  ").concat(u?"":"display: none;","\n}\n.").concat(y,"-container.closed .").concat(y,"-button :first-child {\n  transform: rotate(").concat(i?"":"-","30deg) translateX(2px);\n}\n.").concat(y,"-container.closed .").concat(y,"-button :last-child {\n  transform: rotate(").concat(i?"-":"","30deg) translateX(-2px);\n}\n").concat(this.getFixedSelectorStyles(y,d,i,g,f),"\n</style>\n"))},D.prototype.getContainerBorderSize=function(){var t=this.getAttributes().borderWidth;return Number(t.substring(0,t.length-2))},D.prototype.getContainerBordersSize=function(){var t=this.getAttributes().compact;return this.getContainerBorderSize()*(t?2:1)},D.prototype.getAttributes=function(){return this.attributes},D.prototype.insert=function(){var t=this,e=(this.logger.debug("".concat(this.getLogContext()," add widget")),this.createWidget(this.getFuseSlotHeight())),n=this.createStyles(),e=this.addContent(e,n);return window.requestAnimationFrame(function(){t.show()}),this.getHideAtElement()&&this.setHideAtElementListener(),[e]},D.prototype.hideAtElementListener=function(){var t=this.getContainerElement(),e=this.getHideAtElement(),n=this.getAttributes().isHideForever;u(e)&&jt(this.viewportInfo.getViewportStatus(),e,1,0)?t.classList.contains("closed")||(this.hide(),n&&clearInterval(this.hideAtElementInterval)):t.classList.contains("closed")&&this.show()},D.prototype.setHideAtElementListener=function(){var t=this;this.getHideAtElement()&&(this.hideAtElementInterval=setInterval(function(){t.hideAtElementListener()},500))},D.prototype.isHideSelectorVisible=function(){var t=this.getHideAtElement();return!(!t||!jt(this.viewportInfo.getViewportStatus(),t,1,0))},D.prototype.onBreakpointChange=function(){var t,e,n,i,o=this.getAttributes().compact,r=this.getContainerElement(),s=this.getWidgetElement();s&&(t=this.getFuseSlotHeight(),i=(e=this.getFuseSlotWidth())+(n=this.getContainerBordersSize()),r.style.height=(0===t?0:t+n)+"px",r.style.display=0===t?"none":"block",o&&t&&(r.style.width=i+"px",s.style.width=e+"px"),s.style.height=t+"px",0===t||this.isHideSelectorVisible()?this.updateFixedElement(!0):this.updateFixedElement(),this.getStylesElement().innerHTML=this.createStyles().innerHTML)},D.prototype.delete=function(){var t=this.getStylesElement(),e=this.getContainerElement();return this.updateFixedElement(!0),!(!t||!e)&&(t.remove(),e.remove(),!0)},D.prototype.show=function(){var e=this,n=this.slot.id;return this.logger.debug("".concat(this.getLogContext()," showing with waitForCreative ").concat(this.waitForCreative)),this.loadingByCreative||(this.waitForCreative&&!this.hasLoadedCreative?(this.loadingByCreative=!0,this.registerAdRendered(function(t){-1!==t.slot.getSlotElementId().indexOf(n)&&(e.logger.debug("".concat(e.getLogContext()," show widget by creative ").concat(t.slot.getSlotElementId())),!e.isHideSelectorVisible()&&e.loadingByCreative&&e.onShow(),e.loadingByCreative=!1,e.hasLoadedCreative=!0)})):this.onShow()),!0},D.prototype.onShow=function(){var e=this,t=this.getContainerElement();t.classList.remove("closed"),t.style.visibility="visible",this.updateFixedElement(),this.apiV3.getSlotsForTemplateId(this.slot.id).forEach(function(t){t&&e.apiV3.enableRefreshByZone(t.slotDivId)}),this.onShowCloseCallback()},D.prototype.onClose=function(){var e=this,t=this.getContainerElement();t.classList.add("closed"),t.style.visibility="hidden",this.updateFixedElement(!0),this.apiV3.getSlotsForTemplateId(this.slot.id).forEach(function(t){t&&e.apiV3.disableRefreshByZone(t.slotDivId)}),this.onShowCloseCallback()},D.prototype.hide=function(){return this.logger.debug("".concat(this.getLogContext()," hiding")),this.onClose(),!0},D.prototype.updateFixedElement=function(t){void 0===t&&(t=!1),this.logger.debug("".concat(this.getLogContext()," updateFixedElement ").concat(t?"restore":"update"));var e,n=this.getFixedElement();n&&(e=this.getFixedClass(),t?n.classList.remove(e):n.classList.add(e))},D);function D(t,e,n,i,o,r,s){void 0===s&&(s=!0);var a=ko.call(this,t,e,n)||this;return a.slot=t,a.logger=e,a.viewportInfo=n,a.registerAdRendered=i,a.apiV3=o,a.onShowCloseCallback=r,a.waitForCreative=s,a.loadingByCreative=!1,a.hiddenForever=!1,a.hasLoadedCreative=!1,a.type="sticky",a.attributes=a.makeAttributes(),a}var Bo,Mo,xo=this&&this.__extends||(Bo=function(t,e){return(Bo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}Bo(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),Uo=this&&this.__assign||function(){return(Uo=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},Fo=(xo(Go,Mo=n),Go.prototype.getAttributes=function(){return Uo({selector:".adBreak",showBanner:!1,height:"100vh",zIndex:1e7,top:"auto"},this.slot.interscrollerAttributes)},Go.prototype.insert=function(){var t=this.getAttributes(),e=t.showBanner,n=t.top,i=t.zIndex,o=t.height,t=t.selector,r=this.getFuseSlotHeight(),s=this.createSlotElement(),a=this.getClassName(),e=e?'<div class="'.concat(a,'-container-message banner_top">Advertisement</div>'):"",e=this.toHTML('\n    <div class="'.concat(a,'-container">\n      ').concat(e,'\n        <div class="').concat(a,'-scroll-clip">\n          <div class="').concat(a,'">').concat(s.outerHTML,"</div>\n        </div>\n    </div>\n  ")),i=this.toHTML('\n  <style id="'.concat(a,'-styles">\n  .').concat(a,"-container {\n    width: 100vw;\n    min-height: ").concat(o,";\n    z-index: ").concat(i,";\n    position: relative;\n    display: ").concat(0===r?"none":"block",";\n  }\n\n  .").concat(a,"-container-message {\n    background-color: black;\n    color: white;\n    padding: .5em;\n    text-align: center;\n    font-family: sans-serif;\n  }\n\n  .").concat(a,"-scroll-clip {\n    position: absolute;\n    left: 0;\n    width: 100%;\n    height: 100%;\n    margin: 0;\n    padding: 0;\n    clip-path: inset(0px);\n    clip: rect(0px, auto, auto, 0px);\n    min-height: ").concat(o,"\n  }\n\n  .").concat(a," {\n    position: fixed;\n    top: ").concat(n,";\n    left: 0;\n    width: 100%;\n    height: 100%;\n    margin: 0;\n    padding: 0;\n    bottom: 0;\n    transform: translateZ(0px);\n  }\n  </style>\n  ")),r=document.querySelector("body");if(r){o=document.querySelector(t);if(o)return r.insertAdjacentElement("beforeend",i),o.appendChild(e),e.style.marginLeft="-".concat(e.getBoundingClientRect().x,"px"),[s];this.logger.info("".concat(this.getLogContext()," insertionPoint with selector not found: ").concat(t))}return[]},Go.prototype.onBreakpointChange=function(){var t=this.getFuseSlotHeight(),e=this.getContainerElement();e&&(e.style.display=0===t?"none":"block")},Go.prototype.delete=function(){var t=this.getStylesElement(),e=this.getContainerElement();return!(!t||!e)&&(t.remove(),e.remove(),!0)},Go.prototype.hide=function(){return this.getContainerElement().style.display="none",!0},Go.prototype.show=function(){return this.getContainerElement().style.display="block",!0},Go);function Go(){var t=null!==Mo&&Mo.apply(this,arguments)||this;return t.type="interscroller",t}var Wo,zo,xo=this&&this.__extends||(Wo=function(t,e){return(Wo=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}Wo(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),jo=this&&this.__assign||function(){return(jo=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},qo=(xo(Vo,zo=n),Vo.prototype.getAttributes=function(){return jo(jo({},this.slot.dynamicAttributes),{skip:Number(this.slot.dynamicAttributes.skip||0),each:Number(this.slot.dynamicAttributes.each||0),incrementEach:Number(this.slot.dynamicAttributes.incrementEach||0),repeatHeight:Number(this.slot.dynamicAttributes.repeatHeight||1e3)})},Vo.prototype.createElement=function(t,e){void 0===t&&(t=""),void 0===e&&(e="");var n=this.createSlotElement();return t&&t.split(" ").forEach(function(t){return n.classList.add(t)}),e&&(n.style.cssText=e),n},Vo.prototype.canBeInserted=function(t){var e=this.getLogContext();if(!t)return this.logger.warn("".concat(e," Selector should be defined")),!1;var n=document.querySelectorAll(t);return n.length?(this.logger.debug("".concat(e," Page has ").concat(n.length," elements suitable for selector ").concat(t)),!0):(this.logger.info("".concat(e," No element with selector ").concat(t," found")),!1)},Vo.prototype.notFuseSlot=function(t){return!t||t.getAttribute("data-fuse")!==this.slot.id||(this.logger.debug("".concat(this.getLogContext()," Skip insertion cause slot already inserted")),!1)},Vo.prototype.filterNodes=function(t){var e=this.getAttributes(),n=e.skip,i=e.each,o=e.position,r=e.incrementEach,s=[],a=0,c=i;return t.forEach(function(t,e){e+=1;if(n&&e<=n)return!1;if("incontent"!==o&&c){if((e-n-a)%c!=0)return!1;r&&(a+=c,c+=r)}s.push(t)}),s},Vo.prototype.getZoneDiv=function(t,e){return(e=void 0===e?!1:e)?t.querySelector("div[data-fuse]"):t},Vo.prototype.insert=function(){var c=this,t=this.getAttributes(),e=t.selector,u=t.position,l=t.classNames,d=t.css,g=t.wrapperContent,p=t.repeatHeight;if(!this.canBeInserted(e))return this.logger.debug("".concat(this.getLogContext()," Injection skipped")),[];var t=document.querySelectorAll(e),h=0,f=[];return this.filterNodes(t).forEach(function(t){var e=c.createElement(l,d),n=e,i=(g&&(e=c.wrapElement(e,g)),t.nextElementSibling),o=t.parentNode,r=t.previousElementSibling,s=t.lastElementChild;switch(u){case"after":c.notFuseSlot(i)&&(o.insertBefore(e,i),f.push(n));break;case"before":c.notFuseSlot(r)&&(o.insertBefore(e,t),f.push(n));break;case"replace":t.replaceWith(e),f.push(n);break;case"incontent":var a=t.getBoundingClientRect().top+t.getBoundingClientRect().height+document.documentElement.scrollTop,a=Math.floor(a/p);h<a&&(h=a,c.notFuseSlot(i)&&(o.insertBefore(e,i),f.push(n)));break;default:c.notFuseSlot(s)&&(t.appendChild(e),f.push(n))}}),f},Vo.prototype.wrapElement=function(t,e){var n=document.createElement("div");return n.innerHTML=e,n.firstElementChild.appendChild(t),n.firstElementChild},Vo.prototype.delete=function(){var t=document.querySelectorAll('[data-fuse="'.concat(this.slot.id,'"]'));return t.forEach(function(t){t.remove()}),0<t.length},Vo.prototype.hide=function(){throw new Error("Method not implemented.")},Vo.prototype.show=function(){throw new Error("Method not implemented.")},Vo.prototype.onBreakpointChange=function(){throw new Error("Method not implemented.")},Vo);function Vo(){var t=null!==zo&&zo.apply(this,arguments)||this;return t.type="dynamic",t}O.prototype.getStickySlots=function(){return this.settings.getFuseSlots().filter(function(t){return null==(t=t.attributes)?void 0:t.sticky})},O.prototype.getInterscrollerSlots=function(){return this.settings.getFuseSlots().filter(function(t){return null==(t=t.attributes)?void 0:t.interscroller})},O.prototype.getDynamicSlots=function(){return this.settings.getFuseSlots().filter(function(t){return null==(t=t.attributes)?void 0:t.dynamic})},O.prototype.getScrollToStickSlots=function(){return this.settings.getFuseSlots().filter(function(t){return null==(t=t.attributes)?void 0:t.scrollToStick})},O.prototype.getMiniscrollerSlots=function(){return this.settings.getFuseSlots().filter(function(t){return null==(t=t.attributes)?void 0:t.miniscroller})},O.prototype.isSlotInjected=function(t){return null!==document.querySelector('[data-fuse="'.concat(t.id,'"]'))},O.prototype.getWidget=function(e){return this.widgets.filter(function(t){return t.slot.id===e.id})[0]},O.prototype.removeWidget=function(t){var e=this.getWidget(t);return e?(e.delete(),this.logger.debug("[WIDGETS][".concat(t.id,"] Widget deleted")),!0):(this.logger.debug("[WIDGETS][".concat(t.id,"] Widget was not found")),!1)},O.prototype.cleanup=function(){var e=this;this.getWidgetSlots().forEach(function(t){return e.removeWidget(t)})},O.prototype.handleBreakpointChange=function(){var e=this,t=this.getStickySlots(),n=this.getInterscrollerSlots();this.logger.info("[WIDGETS] onBreakpointChange Stickies: ".concat(t.length," Scrolls: ").concat(n.length)),[].concat(t,n).forEach(function(t){t=e.getWidget(t);t&&t.onBreakpointChange()})},O.prototype.getWidgetSlots=function(){return[].concat(this.getDynamicSlots(),this.getInterscrollerSlots(),this.getStickySlots())},O.prototype.getWidgetsWithSelector=function(){return[].concat(this.getDynamicSlots(),this.getInterscrollerSlots())},O.prototype.insertStyles=function(t){var e=document.createElement("div");e.innerHTML=t,document.querySelector("body").insertAdjacentElement("beforeend",e.firstElementChild)},O.prototype.cleanupDynamicSlots=function(){this.getDynamicSlots().forEach(function(t){document.querySelectorAll('[data-fuse="'.concat(t.id,'"]')).forEach(function(t){t.remove()})})},O.prototype.injectWidget=function(t){var e=this,n=(this.logger.debug("[WIDGETS][".concat(t.id,"] Inject widget")),t.attributes),i=n.sticky,o=n.interscroller,n=n.dynamic,r=this.getWidget(t),s=!1;if((i||o)&&this.isSlotInjected(t))this.logger.debug("[WIDGETS][".concat(t.id,"] Skip injection. DOM element exists"));else{if(!r){if(i)r=new No(t,this.logger,this.viewportInfo,function(t){return ke(t)},this.apiV3,function(){e.updateFuseStyles()},!this.settings.isYandexEnabled()),s=t.stickyAttributes.isTop;else if(o)r=new Fo(t,this.logger,this.viewportInfo);else{if(!n)return void this.logger.warn("[WIDGETS][".concat(t.id,"] Skip injection of unknown widget"));this.logger.debug("[WIDGETS][".concat(t.id,"] Injecting dynamic slot with attributes ").concat(JSON.stringify(t.dynamicAttributes))),r=new qo(t,this.logger,this.viewportInfo)}this.widgets.push(r)}i=r.insert();i.forEach(function(t){e.logger.debug("[WIDGETS][".concat(t.id,"] Run queueZone")),e.apiV3.queueZone(t.id)}),0<i.length&&this.apiV3.runAuction(),s&&this.updateFuseStyles()}},O.prototype.render=function(){var n=this;this.getWidgetSlots().forEach(function(t){var e;!t.injectConditionConfig||(e=n.conditionFactory.buildActivator(t.injectConditionConfig,t.id,n.apiV3,function(){n.injectWidget(t)})).checkCondition()?n.injectWidget(t):e.enableTriggers()})},O.prototype.initConditions=function(){this.inited?this.logger.debug("[WIDGETS] Skipped initialisation as it is already initialised"):(this.logger.debug("[WIDGETS] Init conditions"),this.render(),this.inited=!0)},O.prototype.getMiniScrollersTopOffset=function(){var n=this,i=0,t=this.settings.getTopStickyHeaderSelector();return t&&(t=document.querySelector(t))&&(i+=t.clientHeight,this.logger.debug("[WIDGETS] miniscrollers offset set to ".concat(i," because of topStickyHeader"))),this.getStickySlots().forEach(function(t){var e;null!=(e=t.stickyAttributes)&&e.isTop&&(e=n.getWidget(t))&&!e.getContainerElement().classList.contains("closed")&&(e=n.settings.maxSlotHeightForBreakpoint(t,n.viewportInfo.getCurrentBreakpoint().name),i+=null!=e?e:0,n.logger.debug("[WIDGETS] miniscrollers offset set to ".concat(i," because of top sticky")))}),i},O.prototype.injectFuseStyles=function(){var t,e,n;document.getElementById("publift-fuse-styles")?this.logger.debug("[WIDGETS] styles already injected"):(t="",e=this.getMiniScrollersTopOffset(),this.settings.isMiniScrollersEnabled()&&(this.logger.debug("[WIDGETS] inject fuse styles"),n="\n      .fuse-slot-mini-scroller .fuse-slot {\n        top: ".concat(0|e,"px;\n        position: sticky !important;\n        overflow: hidden !important;\n      }\n      .fuse-slot-mini-scroller {\n        overflow: initial !important;\n        display: block !important;\n      }\n      "),this.logger.debug("[WIDGETS] injected miniScroller styles"),t+=n),n="\n    .fuse-slot-scroll-to-stick .fuse-slot {\n      z-index: 9999;\n      top: ".concat(0|e,"px;\n      position: fixed;\n      width: 100%;\n      left: 0px;\n      pointer-events: none;\n    }\n    "),this.insertStyles('<style id="publift-fuse-styles">'.concat(t+=n,"</style>")))},O.prototype.updateFuseStyles=function(){var t=document.getElementById("publift-fuse-styles");t&&t.remove(),this.injectFuseStyles()},O.prototype.getScrollToStickPrevElement=function(t){var e=t.previousElementSibling;return e||this.getScrollToStickPrevElement(t.parentElement)},O.prototype.addScrollToStickListener=function(){var i=this,o=this.getMiniScrollersTopOffset(),t=this.getScrollToStickSlots();t.length&&(this.logger.debug("[WIDGETS] scrollToStick slots found ".concat(this.getScrollToStickSlots().length,". Attach scroll listener")),this.viewportInfo.browserWindow.addEventListener("scroll",function(){t.forEach(function(n){document.querySelectorAll('[data-fuse="'.concat(n.id,'"]')).forEach(function(t){var e=i.getScrollToStickPrevElement(t);e&&e.getBoundingClientRect().y+e.getBoundingClientRect().height-o<0?(i.logger.debug("[WIDGETS][".concat(n.id,"] scrollToStick set")),t.classList.add("fuse-slot-scroll-to-stick")):(i.logger.debug("[WIDGETS][".concat(n.id,"] scrollToStick removed")),t.classList.remove("fuse-slot-scroll-to-stick"))})})},!0))};var Ho=O;function O(t,e,n,i,o,r){var s=this;this.logger=t,this.settings=e,this.apiV3=n,this.conditionFactory=i,this.viewportInfo=o,this.inited=!1,this.widgets=[],r.subscribe(function(){return s.handleBreakpointChange()})}function Zo(){}Zo.prototype.getWidgetsRenderer=function(){return this.widgetsRenderer||(this.widgetsRenderer=new Ho(p.getLogger(),f,To.getApiV3(),Ci.getInsertConditionFactory(),l.getViewportInfo(),h.onBreakpointChanged)),this.widgetsRenderer},Zo.prototype.getWidgetsChecker=function(){return this.widgetsChecker||(this.widgetsChecker=new Po(p.getLogger(),this.getWidgetsRenderer())),this.widgetsChecker},Zo.prototype.getInterstitialManager=function(){return this.interstitialManager||(this.interstitialManager=new Ao(p.getLogger(),f,Ci.getInsertConditionFactory(),To.getApiV3())),this.interstitialManager};var Qo=new Zo,Jo=this&&this.__assign||function(){return(Jo=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},k=p.getLogger(),Yo=Cn.getGptSlotRegistry(),Ko=a.getReporter(),Xo=co.getFuseSlotRegistry(),$o=co.getController(),tr=Pn.getInitManager(),er=p.getBrowserWindowObject(),xo="onTagInitialised",nr=new ct(k,xo),ir=To.getApiV3(),or=To.getPageManager(),rr=function(t,e){k.debug("[API]: loadSlotById(".concat(t,", ").concat(e,")")),(e?$o.registerZoneAndQueue(e,!0,!0,ir):$o.registerAndQueueLastSlotWithFuseId("".concat(t),!0,!0,ir))||k.debug("[API]: loadSlotById(".concat(t,", ").concat(e,") did not register a slot")),$o.runAuction()},sr=function(t,e,n){k.debug("[API]: setSlotTargetingById(".concat(t,", ").concat(e,", ").concat(n,") started")),!t||"string"!=typeof t&&"number"!=typeof t||Yo.setSlotTargetingById("".concat(t),e,n)},ar=function(t){if(t&&("string"==typeof t||"number"==typeof t))return Yo.getSlots("".concat(t))};var cr={enableApi:function(t){k.debug("[INIT]: Enabling Fuse API"),t.fuseUUID=f.getFuseUUID(),t.initialised=!1,t.init=!1,t.getCurrentBreakpoint=function(){return l.getViewportInfo().getCurrentBreakpoint()},t.pageInit=function(t){return k.debug("[API]: pageInit(".concat(JSON.stringify(t),")")),or.handlePageInitCall(er.location.href,Ko.getElapsedTime(),t)},t.registerAll=function(){return k.debug("[API]: registerAll()"),$o.registerAndRunAuction(!0,!1,ir)},t.registerZone=function(t){k.debug("[API]: registerZone('".concat(t,"')"));t=null==(t=$o.registerZoneAndQueue(t,!0,!1,ir))?void 0:t.slotDivId;return t&&$o.runAuction(),t},t.activateZone=function(t){k.debug("[API]: activateZone('".concat(t,"')")),$o.activateZone(t)},t.states=Ko.states,t.events=Ko.events,t.setTargeting=function(t,e){return k.debug("[API]: setTargeting(".concat(t,", ").concat(JSON.stringify(e),")")),kn(t,e)},t.onSlotRenderEnded=function(e){return ke(function(t){t={slotId:t.slot.getSlotElementId(),hasCreative:!t.isEmpty,gptEvent:t};e(t)})},t.onTagInitialised=function(t){nr.once(t)},t.onSlotsInitialised=function(t){Xo.getSlotsInitObservable().once(t)},t.onSlotInitialised=function(t){Xo.getSlotInitObservable().once(t)},t.privateApi={getWidgetRenderer:function(){return Qo.getWidgetsRenderer()},getInitStatus:function(){return tr.getInitStatus()},getSlotProblems:function(){return Ko.getSlotProblems()},resetPage:function(){return k.debug("[API]: resetPage()"),or.reset()},runAuctionAllActiveSlots:function(){return k.debug("[API]: runAuctionAllActiveSlots()"),$o.runAuctionAllActiveSlots()},setLogLevel:function(t){return k.setLogLevel(t)},getLogLevel:function(){return k.getLogLevel()},getLogs:function(){return k.getLogs()},getAuctionState:function(){return co.getAuctionExecutor().getStateView()},getSlotTestUrls:function(){return f.getSlotTestUrls()},isYandexEnabled:function(){return f.isYandexEnabled()},isPrebidEnabled:function(){return f.isPrebidEnabled()},isCmpEnabled:function(){return f.isCmpRequired()},isUamEnabled:function(){return f.isUamEnabled()},isBlockthroughEnabled:function(){return f.isBlockthroughEnabled()}},t.loadSlots=function(){k.debug("[API]: loadSlots()"),$o.loadSlots(t.initialised,ir,function(){return or.reset()})},t.getUnits=function(){return Xo.getElements()},t.loadSlotById=function(t,e){return rr(t,e)},t.refreshSlots=function(){return k.debug("[API]: refreshSlots()"),$o.runAuctionAllActiveSlots()},t.refreshSlotByCode=function(t){return k.debug("[API]: refreshSlotByCode(".concat(t,")")),$o.forceRunAuction(t)},t.getAdSlotsById=function(t){return ar(t)},t.processNewSlots=function(){return k.debug("[API]: processNewSlots()"),$o.registerAndRunAuction(!0,!1,ir)},t.getTargeting=function(){return Dn},t.getAdSlotsByFuseId=t.getAdSlotsById,t.getFuseSlots=t.getSlots,t.getFuseSettings=t.getSettings,t.getFuseUnits=t.getUnits,t.loadFuseSlots=t.loadSlots,t.resetSlots=function(){return k.debug("[API]: resetSlots()"),or.reset()},t.resetFuseSlots=function(){return k.debug("[API]: resetFuseSlots()"),or.reset()},t.loadFuseSlotById=t.loadSlotById,t.setSlotTargetingByFuseId=t.setSlotTargetingById,t.setSlotTargetingById=function(t,e,n){return sr(t,e,n)},t.widgetsRenderer=t.privateApi.getWidgetRenderer(),t.setDefaultTargeting=function(){return k.debug("[API]: setDefaultTargeting()"),Re()},t.getRefreshIntervals=function(){return $o.getRefreshIntervals()},t.disableRefresh=function(){return k.debug("[API]: disableRefresh()"),$o.clearRefreshIntervals()},t.getSlots=function(){return Xo.getSlotTemplates()},t.getSettings=function(){return Jo({},f.getAccountSettings())}},tagInitEmitter:nr,ON_TAG_INIT_EVENT:xo};if(null!=(n=window.self.fusetag)&&n.loading)throw xo="[FUSE]: Fusetag is already initialising, and may have been included in the page twice",console.error(xo),new Error(xo);if(null!=(n=window.self.fusetag)&&n.init)throw xo="[FUSE]: Fusetag is already initialised, and may have been included in the page twice",console.error(xo),new Error(xo);var ur=window.self.fusetag||(window.self.fusetag={que:[]}),x=(ur.loading=!0,a.getReporter()),L=p.getLogger(),lr=(L.log("[INIT] Initialising with UUID ".concat(f.getFuseUUID())),Wi.getUam()),dr=Ni.getConsentManger(),gr=co.getController(),pr=co.getAuctionExecutor(),hr=Pn.getInitManager(),fr=Qo.getWidgetsRenderer(),br=Qo.getInterstitialManager(),mr=To.getApiV3(),yr=a.getTelemetry(),Sr=To.getPageManager(),vr=l.getViewportInfo(),N=a.getComponentStatusStore();function Ir(){if(x.setStateStatus("fuse_queue_start"),fo)bo.error("[INIT] processBacklog() called, but it already ran");else{for(fo=!0,bo.log("[INIT]: Processing fuse queue with ".concat(mo().length," pending items"));0<mo().length;){var t=mo().shift();if("function"==typeof t)try{bo.debug("[INIT]: Calling queued function"),t.call(),t.called=!0}catch(t){bo.error("[INIT]: Error calling queued function:",t.message,t.stack)}else bo.error("[INIT]: Commands written into fusetag.que.push must be wrapped in a function")}So()}x.setStateStatus("fuse_queue_finish")}function Er(t,e,n){t?(L.debug("[INIT]: Running second (".concat(e,") docReady auto-scan and auction")),x.setStateStatus("second_autoscan_".concat(e,"_start")),gr.registerAndRunAuction(!0,!1,mr),x.setStateStatus("second_autoscan_".concat(e,"_finish")),L.debug("[INIT]: Finished second docReady DOM scan")):N.updateState("docReadyScan",Nt(n,x.getElapsedTime(),void 0))}function wr(){var e=Lt(x.getElapsedTime());N.updateState("gpt",e),H(K(),"simulate gpt init delay",L,function(){var t;t=function(){y(function(){N.updateState("gpt",Nt(e,x.getElapsedTime(),void 0))})},m.setStateStatus("gpt_load_start"),Ie(),ve(function(){m.setStateStatus("gpt_load_finish")}),y(function(){b.debug("[GPT]: Queued events beginning to execute"),m.setStateStatus("gpt_queue_start"),V(!f.isCmpRequired(),function(){Fe(!0)}),De(),d.enableServices(),t()}),y(function(){br.initInterstitial()}),ke(function(t){return pr.reportOnRenderEndedEvent(t)}),xe(function(t){return pr.reportOnLoadEvent(t)}),Le(function(t){return pr.reportSlotResponseReceived(t)}),f.getUseTelemetry()&&Ne(function(t){var e=t.slot.getAdUnitPath(),t=f.getFuseSlots().filter(function(t){return t.slot===e})[0];t&&yr.recordSlotRequest(t.id)})})}function Cr(){x.setStateStatus("fuse_bootstrap_start"),cr.enableApi(ur);var e=f.getTagStartCutoffMs(),t=x.getElapsedTime();if(g(e)||t<e){f.isCmpRequired()?dr.enable():N.updateState("cmp",kt()),f.isQuantcastEnabled()&&H(Y(),"simulate quantcast load delay",L,function(){return Ni.getQuantcastLoader().load()}),f.isPrebidEnabled()?(e=f.getPrebidTagStartCutoffMs(),o=x.getElapsedTime(),g(e)||o<e?(n=function(t){return H(X(),"simulate prebid download delay",L,function(){var e=Lt(x.getElapsedTime(),t);N.updateState("prebid",e),In.enable(function(t){t?In.pushToPrebidQue(function(){N.updateState("prebid",Nt(e,x.getElapsedTime(),void 0))}):N.updateState("prebid",xt())})})},i=vr.getCurrentBreakpoint().name,f.isPrebidEnabledAtBP(i)?n(!1):(L.info("[INIT]: Prebid not enabled at breakpoint ".concat(i,", deferring initialisation")),N.updateState("prebid",Ot()),h.onBreakpointChanged.subscribe(function(t){t=t.name;f.isPrebidEnabledAtBP(t)&&"deferred"===N.state.prebid._tag&&(L.info("[INIT]: Prebid is enabled for breakpoint ".concat(i,", loading it now")),n(!0))}))):(N.updateState("prebid",xt()),L.info("[INIT]: Skipping prebid load because fuse took ".concat(o,"ms to begin loading")))):(N.updateState("prebid",kt()),L.info("[INIT]: Not loading Prebid because it is disabled")),f.isUamEnabled()?(e=f.getUamTagStartCutoffMs(),o=x.getElapsedTime(),g(e)||o<e?(r=function(e){H($(),"simulate uam download delay",L,function(){var t=Lt(x.getElapsedTime(),e);N.updateState("uam",t),lr.load(f.isCmpRequired(),function(){N.updateState("uam",Nt(t,x.getElapsedTime(),void 0))})})},f.isUamEnabledAtBP(vr.getCurrentBreakpoint().name)?r(!1):(N.updateState("uam",Ot()),h.onBreakpointChanged.subscribe(function(t){t=t.name;f.isUamEnabledAtBP(t)&&"deferred"===N.state.uam._tag&&(L.info("[INIT]: UAM is enabled for breakpoint ".concat(t,", loading it now")),r(!0))}))):(N.updateState("uam",xt()),L.info("[INIT]: Deferring UAM load because fuse took ".concat(o,"ms to begin loading")))):(N.updateState("uam",kt()),L.info("[INIT]: Not loading Uam because it is disabled")),f.isYandexEnabled()?(N.updateState("gpt",kt()),a=Lt(x.getElapsedTime()),N.updateState("yandex",a),window.yaContextCb?N.updateState("yandex",Nt(a,x.getElapsedTime(),void 0)):((u=(e=p.getBrowserWindowObject().document).createElement("script")).innerHTML="window.yaContextCb=window.yaContextCb||[]",e.head.appendChild(u),(u=e.createElement("script")).src="https://yandex.ru/ads/system/context.js",u.async=!0,e.head.appendChild(u),s=setInterval(function(){var t;null!=(t=null==(t=window.Ya)?void 0:t.Context)&&t.AdvManager&&(N.updateState("yandex",Nt(a,x.getElapsedTime(),void 0)),clearInterval(s))},100))):(N.updateState("yandex",kt()),wr(),y(function(){je.enableIfApplicable()}));var n,i,o,r,s,a,c,u,l,d=p.getBrowserWindowObject(),e=(V(f.isConfiantEnabled(),function(){Ye.enable(f.getConfiantId())}),V(f.isId5Enabled(),function(){nn.enable()}),V(f.isIdentityEnabled(),function(){cn.enable(d)}),V(f.isResponsiveEnabled(),function(){gr.configureResponsive()}),hr.setIsLowDwellPage(Sr.isLowDwellUrl(d.location.toString())),L);f.getV2CompatOverrides(),To.getApiV3();try{e.log("[INIT][onFuseLoadCallback] Start"),e.debug("[INIT][onFuseLoadCallback] Finish")}catch(t){e.error("[INIT][onFuseLoadCallback] Encountered error during evaluation",t)}yr.recordFuseLoad(),f.isScanDOMOnPageLoad()?(u=document.readyState,l=Lt(x.getElapsedTime()),N.updateState("docReadyScan",l),"complete"===u?(L.info("[INIT]: Document state is already 'complete'"),Er(!1,u,l)):(c=!1,"interactive"===u&&(L.info("[INIT]: Document state is already 'interactive'"),Er(!(c=!0),u,l)),document.addEventListener("readystatechange",function(){var t=document.readyState,e=(x.setStateStatus("document_readystatechange_".concat(t)),L.info("[INIT]: Received document '".concat(t,"' listener callback")),c);c=!0,Er(e,t,l)}))):N.updateState("docReadyScan",kt()),h.onInitManagerReady.immediateOrOnce(function(){Ir(),f.isWidgetRendererEnabled()&&(fr.initConditions(),Qo.getWidgetsChecker().start(fr.getWidgetsWithSelector()),fr.addScrollToStickListener()),fr.injectFuseStyles(),ur.initialised=!0,ur.init=!0,ur.loading=!1,x.setStateStatus("tag_initialised"),hr.setTagInitialised(),(Sr.isPageInitCalled()||f.isScanDOMOnPageLoad())&&(x.setStateStatus("fuse_trigger_auto_auction_start"),gr.registerAndQueue(!0,!1,mr),x.setStateStatus("fuse_trigger_auto_auction_finish")),x.setStateStatus("on_tag_init_event_start"),cr.tagInitEmitter.emit({}),h.onTagInitComplete.emit({tagInitUrl:d.location.href}),x.setStateStatus("on_tag_init_event_finish"),gr.runAuction();var t=h.onPageInit;t.subscribe(function(){return br.initInterstitial()}),t.subscribe(function(){L.debug("[PAGE]: Registering slots and running auction after PageInit"),hr.setIsLowDwellPage(Sr.isLowDwellUrl(d.location.toString())),gr.registerAndRunAuction(!0,!1,mr)})}),x.setStateStatus("fuse_bootstrap_finish")}else L.warn("[INIT]: Fuse will not show ads because it took ".concat(t,"ms before it began loading")),x.setStateStatus("fuse_bootstrap_finish")}H(tt("fuseDelayInit"),"simulate slow fuse download",L,Cr)});