/*! 20231130-4-RELEASE */ function _typeof(e){"@babel/helpers - typeof";return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}!function(e){var t='TFASC';t.indexOf("{jsScope}")>-1&&(t="TRC"),e[t]||(e[t]={})}(window),function(e,t){e.TRC=e.TRC||{};var n=function e(){return!0},r=function n(r,i,o,s){var a=r+"/"+encodeURIComponent(o||e.TRC.publisherId)+"/log/3"+"/"+i;return s&&(a+="?"+t.TRCLogger.formatParams(s)),a},i=function t(r,i,s){var a,c=new(e.XDomainRequest||e.XMLHttpRequest);return c.open(r,i),c.onload=n,c.onerror=n,c.ontimeout=n,c.onprogress=n,c.withCredentials=!0,s&&o(c,s),c},o=function e(t,n){for(var r in n)n.hasOwnProperty(r)&&t.setRequestHeader(r,n[r])};e.TRC.TRCLogger=t.TRCLogger={post:function n(o,s,a,c,u,l){var f=r(o,s,c,u),d=i("POST",f);l&&"function"==typeof e.navigator.sendBeacon?e.navigator.sendBeacon(f,t.TRCLogger.formatBeaconParams(a)):(d.setRequestHeader&&d.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),d.send(t.TRCLogger.formatParams(a)))},get:function e(t,n,o,s){if(o.headers){var a=o.headers;delete o.headers}var c=r(t,n,s,o),u;i("GET",c,a).send()},formatParams:function e(t){var n=[];for(var r in t)t.hasOwnProperty(r)&&n.push(encodeURIComponent(r)+"="+encodeURIComponent(t[r]));return n.join("&")},formatBeaconParams:function e(t){var n="",r;for(var i in t)t.hasOwnProperty(i)&&(n+=i+"="+encodeURIComponent(t[i])+"&");return new Blob([n.slice(0,-1)],{type:"application/x-www-form-urlencoded"})},reportES:function e(n){if(t&&t.util&&t.util.isPercentEnabled(TRCImpl.global,"enable-rbox-es-events")){var r=TRCImpl&&TRCImpl.global&&TRCImpl.global["rbox-es-events-url"]||"https://vidanalytics.taboola.com/putes";r=r+"/"+n.index;var i={timestamp:(new Date).toISOString(),name:n.name};for(var o in n.data)i[o]=n.data[o];if("function"==typeof navigator.sendBeacon)navigator.sendBeacon(r,JSON.stringify(i));else{var s=new XMLHttpRequest;s.open("POST",r,!0),s.send(JSON.stringify(i))}}}}}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t){if(t&&!t.MessageDelayer){var n=function n(r){return function(n){var i=n.detail,o=n.type,s=""+i[this.groupingKeyName],a=this.delayedEventsMap[s],c=t.eventUtils.getDateNow();if(a){this.timeoutHandles[s]&&(clearTimeout(this.timeoutHandles[s]),this.timeoutHandles[s]=null);var u=[].concat(a);this.delayedEventsMap[s]=[];for(var l=0;l=0?"TRC":'TFASC']),function(e){e.TRC=e.TRC||{},e.TRC.sharedObjects=e.TRC.sharedObjects||{},e.TRC.sharedObjects.loadedScripts=e.TRC.sharedObjects.loadedScripts||{},e.TRC.sharedObjects.loadedPixels=e.TRC.sharedObjects.loadedPixels||{}}(window),function(e,t,n){!function(){if("function"==typeof e.CustomEvent)return!1;function n(e,n){n=n||{bubbles:!1,cancelable:!1,detail:void 0};var r=t.createEvent("CustomEvent");return r.initCustomEvent(e,n.bubbles,n.cancelable,n.detail),r}n.prototype=e.Event.prototype,e.CustomEvent=n}(),n.eventUtils=n.eventUtils||{},n.eventUtils.dispatchEvent=n.eventUtils.dispatchEvent||function(e,t){"function"==typeof CustomEvent&&document.dispatchEvent(new CustomEvent(e,{detail:t||{}}))},n.eventUtils.safeAddEventListener=n.eventUtils.safeAddEventListener||function(e,t){document.addEventListener(e,function(e){try{t.call(this,e)}catch(e){}})},n.eventUtils.safeAddEventListenerToWindow=n.eventUtils.safeAddEventListenerToWindow||function(e,t){window.addEventListener(e,function(e){try{t.call(this,e)}catch(e){}})},n.eventUtils.getDateNow=n.eventUtils.getDateNow||function(){var e,t;if(Date.now){if("number"==typeof(e=Date.now()))return e;if("number"==typeof(t=Number(e)))return t}return(new Date).getTime()},n.eventUtils.hashString=n.eventUtils.hashString||function(e){var t=0;if(0==e.length)return t;for(var n=0;n=0?"TRC":'TFASC']),function(e,t){e._tfa=e._tfa||[],e._tfa.config||(e._tfa.TfaConfig=function(){this.configMap={}},e._tfa.TfaConfig.prototype={safeGet:function e(t,n,r){var i,o,s;if(r&&this.configMap[r])i=""+r;else{if(!this.firstPublisherId)return n;i=this.firstPublisherId}try{return void 0===(s=(o=this.configMap[i])[t])?n:s}catch(e){return n}},hasValidConfig:function e(){return!!this.firstPublisherId},addConfig:function e(t,n){"string"==typeof n||n instanceof String||(this.firstPublisherId||(this.firstPublisherId=t),this.configMap[""+t]=n)}},e._tfa.config=new e._tfa.TfaConfig,e._taboola=e._taboola||[]),e._tfa.config.addConfig(1231667,{"tfa:event-host-map":{"pre_d_eng_tb": "trc-events.taboola.com"},"tfa:add-item-url:event-list":"*","tfa:trk:is-unified-page-view":true,"eid:send-eid-encoded":true,"tfa-uid:send-ids-to-cds":false,"cds:send-uad-req":true,"cds:send-dnid-req":true,"tfa:get-publisher-id-from-baker":true,"tfa:trk:flc-enabled":true,"tfa:engagement:return-visits:is-enabled":true,"tfa:collect-eid-from-page":false,"eid-enabled":"false","eid:tfa:common-eid-keywords":"help,support,contact,readme,test,info,reply,careers,spam,login,subscribe,feedback,reachus,customers,cookie,members","trc:user-history:conversion-incrementality-enable":false,"tfa:trk:topics-enabled":true})}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t,n){"use strict";var r=e[n.jsScope],i={map:function e(t,n){if("function"==typeof Array.prototype.map)return n.map(t);for(var r=[],i=0;i=r?i.slice(r-1).join(n):[])},Q=function e(t){if(!t)throw new Error("Invalid URL!");this.href=t;var n=J(t,"#",2);return this.hash=n.length>1?"#"+n.pop():"",t=n[0],n=J(t,"?",2),this.search=n.length>1?"?"+n.pop():"",t=n[0],n=J(t,"://",2),this.protocol=n.length>1?n.shift()+":":"",t=n[0],n=J(t,"/",2),this.pathname=n.length>1?"/"+n.pop():"/",t=n[0],n=J(t,"@",2),this.auth=n.length>1?n.shift():"",t=n[0],n=J(t,":",2),this.port=n.length>1?parseInt(n.pop()):0,this.host=n[0],this},Y={"http:":1,"https:":1};Q.prototype.toString=function(e){return(this.host?this.protocol+"//"+(this.auth?this.auth+"@":"")+this.host+(this.port?":"+this.port:""):"")+this.pathname+this.search+(e?"":this.hash||"")},Q.prototype.switchProtocol=function(e,t){var n=this instanceof Q?this:new Q(this),r;return Y[e]&&(t&&"https:"===n.protocol||(n.protocol=e)),(r=n.toString(!1)).length>1?r:""},Q.prototype.getParameter=function(e){for(var t,n=(this instanceof Q?this:new Q(this)).search.substr(1).split(/&/),r=0;r0?n[n.length-1]:null},ue=function e(){r.eventUtils.dispatchEvent(x,M)},le=function t(i,o){if(e.clearTimeout(i[v]),o&&o.trc){if(o.trc.ui?(o.trc["DNT"]&&"TRUE"===o.trc["DNT"].toUpperCase()?localStorage.removeItem("taboola global:user-id"):o.trc["cm"]||localStorage.setItem("taboola global:user-id",o.trc["ui"]),j=B.USER_ID_SET):j=B.UNINITIALIZED,o.trc.sd&&!o.trc["cm"]&&localStorage.setItem(i.publisherId+":session-data",o.trc["sd"]),o.trc["vl"]&&o.trc["vl"].length){var s=o.trc["vl"][0].ri;i.isMediaRequest||(e.TRC.events_ri=s),i[m]=s,i[S]=R,r.eventUtils.dispatchEvent(r.sharedEvents.REQUEST_ID_CREATED,{publisherId:i.publisherId,requestId:s})}i.isMediaRequest&&r.trk.rboxNotLoaded()&&(o.trc.stp&&r.trk.loadPixels(o.trc.stp),o.trc.jst&&r.trk.loadScriptTags(o.trc.jst))}i[S]!==R&&(i[S]=k,r.eventUtils.dispatchEvent(r.sharedEvents.REQUEST_ID_CREATION_ERROR,{publisherId:i.publisherId})),i.isMediaRequest||(e.TRC.trkRequestStatus=!(O.indexOf(i[S])>=0)),e.TRC.alertVVResponseLoaded&&e.TRC.alertVVResponseLoaded(n.tblVersion),ee(i),ue()},fe=function(){var e,t=function e(){try{return decodeURI(top.window.document.referrer)}catch(e){}return null},n=/https?:\/\/\w+\.taboola(?:syndication)?\.com/,r=function e(t){return n.test(t)?t.split("?")[0]:t.substr(0,400)},i,o=[function e(){for(var t=document.head.getElementsByTagName("link"),n=0;nn&&(r=F.substring(0,n-1),F=r.substring(0,r.lastIndexOf("&"))),F},pe=function e(t){var n=ve("usprivacy");if("function"==typeof __uspapi)try{__uspapi("getUSPData",1,function(e,r){r&&e?t(e.uspString):n&&t(n)})}catch(e){throw n&&t(n),new Error("Error while calling __uspapi for getUSPData")}else n&&t(n)},ve=function e(t){var n=t+"=",r="; "+document.cookie;if(r)for(var i=r.split(";"),o=0;o=0&&(n=n.substr(0,t))},r["truncate-at"]||[]);for(var s=new Q(n),a=i.objKeys(r),c=0;c=0&&(s.hash="#"+h)})}}return s.pathname||(s.pathname="/"),"item-id"===t?s.toString().toLowerCase():s.toString()},we=function e(){return Re(de(),"ampproject.net")},Ce=function e(){return Re(de(),"instantarticles.fb.com")},Re=function e(t,n){try{return void 0!==t&&void 0!==n&&t.indexOf(n)>0}catch(e){return!1}},ke=function e(t,r,i){var o=["paramUrl","meta","canonical","og","location"],s={paramUrl:_e,canonical:Oe,og:Ue,location:Pe},a=n.urlExtractOrder&&Array.isArray(n.urlExtractOrder)?n.urlExtractOrder:o,c=0,l,f,d,h="",g=function e(t,n){return Te.call(this,t,n,i)};for(a.push("location");c5)return i.call(this,n,r.trk.encodeItemUrlIfNeeded(o[s].content));return null},Pe=function t(n,r){var o=function t(){var n=e.location,r=i.filter(function(e){return 0!==e.search("trc_")&&"taboola-debug"!==e},n.search.replace(/^\?/,"").split("&")).join("&");return n.origin+n.pathname+"?"+r};return r.call(this,n,o())},De=function e(t){try{var n=i.objKeys(t[0]);for(var r in n)switch(n[r]){case"home":return"home";case"category":return"category";case"text":case"article":return"text";case"search":return"search";case"photo":return"photo";case"other":return"other";case"content_hub":return"content_hub";case"video":default:return"video"}}catch(e){return"video"}},Ae=function e(t){return localStorage.getItem(t+":session-data")},Ne=function e(){return localStorage.getItem("taboola global:user-id")},xe=function e(){return ke("item-url",n.normalizeItemUrl,n.prenormalizeUrlRules)},Me=function e(t){for(var n,r=/^(.*\/libtrc\/.+\/)(?:(?:trk)|(?:tfa))\.js(?:\?(.*))?$/,i=0;i1?a[r[i].index]:a[0];return s},Ve=function t(){if(!e.TRC.AdServerManager){var r=Le();e.TRC.VVReady=Be,ne("//"+r+"/libtrc/vv."+n.tblVersion+".js")}},Be=function t(){e.TRC.adManager=new e.TRC.AdServerManager(n.vvConfig,n.tblVersion),e.TRC.adManager.startVV().then(function(){e.TRC.adManager.run()})},je=function e(t,n){return t?t[n]:t},Ke=function e(t,n,r){if(0===i.objKeys(r).length||D[""+t])return t;var o=document.createElement("a");o.href=f;var s=(o.host||location.host).toLowerCase(),a=(o.href||location.href).toLowerCase(),c=P[n],u=je(r[s],c),l="/",d=["m","mobile","www2","www3"],h=[],g,p,v,m,S;if(!u){for(X(r,h),h.sort(function(e,t){return e[0].length>t[0].length?-1:e[0].length0){if(a.match(v)){u=je(h[g][1],c);break}if(v.indexOf("www.")>-1&&a.match(v.replace("www.",""))){u=je(h[g][1],c);break}}else if(s.match(v)){u=je(h[g][1],c);break}if(!u&&s.indexOf("www.")<0){for(g=0,p=d.length;g-1},!1)},hasRequestEnded:function e(t){return Fe(t,function(e){return O.indexOf(e)>-1||!(U.indexOf(e)>-1)},!1)},getPublisherRequestId:function e(t){var n=ce(t);return n&&n[S]===R?n[m]:null},getPublisherSessionData:function e(t){var n=Ae(t);return n||null},getViewId:function e(){return K},getReferrer:fe,getCcpaParam:function e(t){return pe(t)},COOKIE_BANNER_MAP:G(),parseCookieBanner:function e(){var t,n;try{return(n=H())?n:null===(t=r.trk.parseCookieBannerProvider())?null:(r.trk.parseCookieBannerConsent(t),H())}catch(e){return null}},parseCookieBannerProvider:function e(){var t,n;if(r.trk.cookieBannerProvider)return r.trk.COOKIE_BANNER_MAP[r.trk.cookieBannerProvider.providerName+",V"+r.trk.cookieBannerProvider.version];for(n in r.trk.COOKIE_BANNER_MAP)if(r.trk.COOKIE_BANNER_MAP.hasOwnProperty(n)&&(t=r.trk.COOKIE_BANNER_MAP[n]).isCookieBannerOfProvider())return r.trk.cookieBannerProvider={providerName:t.providerName,version:t.version},t.addListenerForConsentChange(),t;return null},parseCookieBannerConsent:function e(t){try{t.isCookieBannerOpen()||t.parseConsent()}catch(e){}},loadPixels:function t(n){try{return $e(n,e.TRC.sharedObjects.loadedPixels,function(e){var t=new Image;return t.src=e,t})}catch(e){}},loadScriptTags:function t(n){try{return $e(n,e.TRC.sharedObjects.loadedScripts,function(e){return ne(e,null,null,!0)})}catch(e){}},rboxNotLoaded:function t(){return!(e.TRC&&e.TRC.utm)},rboxTrcProtocol:function e(){return n.rboxTrcProtocol},saveGoogleTopicsApiInLocalStorage:function e(){try{if(!t.browsingTopics)return;return t.browsingTopics().then(function(e){for(var t=[],n=0;n0)return n}catch(e){}},hasSuperUTFSeq:function e(t){for(var n=t.split("").map(function(e){return e.charCodeAt(0)}),i=0,o=0;o=3)return!0;i++}return!1},isSuperUTF:function e(t){var n;return t>1200},encodeItemUrlIfNeeded:function e(t){try{if(r.trk.hasSuperUTFSeq(t))return encodeURI(t)}catch(e){}return t}},W()&&!e._tfa.config.safeGet("tfa:trk:enabled",!0,n.bakedPublisherId)||r.trk.init()}(window,document,{bakedPublisherId:1231667,bakedPublisherName:'icmarkets-aud-network',tblVersion:"20231130-4-RELEASE",normalizeItemId:function(itemid,type,canon){if(!canon&&type=='text'&&typeof itemid=='string'&&itemid.search(new RegExp('^https?://'))==0)itemid=itemid.replace(/\?.*/,'', false);return itemid.toLowerCase();},prenormalizeIdRules:{"host":true,"fragment":"^(/video/|!)","query":["p","id"],"truncate-at":["search.searchcompletion.com","org.mozilla.javascript.undefined"],"trailing-dirsep":true},prenormalizeUrlRules:false,normalizeItemUrl:function(itemurl,type,canon){return itemurl;},urlExtractOrder:null,networkMap:{},vvConfig:null,enableVV:false,rboxTrcProtocol:'https:',tfaContext:true,jsScope:'TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC'}),function(e,t){e._tfa=e._tfa||[],t.useStorageDetection=e.TRC.useStorageDetection=e.TRC.useStorageDetection||!0,t.text=t.text||{},t.text.lsplit=t.text.lsplit||function(e,t,n){var r=e.split(t);return r.slice(0,n-1).concat(r.length>=n?r.slice(n-1).join(t):[])},t.tfaUtil=t.tfaUtil||{},t.tfaUtil.safeAddParam=t.tfaUtil.safeAddParam||function(e,t,n){var r,i;n&&t&&e&&(r=encodeURIComponent(e),i=encodeURIComponent(t),n.push(r+"="+i))},t.tfaUtil.getParameterByName=t.tfaUtil.getParameterByName||function(e,t){if(!t||!e)return null;e=e.replace(/[\[\]]/g,"\\$&");var n,r=new RegExp("[?&]"+e+"(=([^&#]*)|&|#|$)").exec(t);return r?r[2]?decodeURIComponent(r[2].replace(/\+/g," ")):"":null};var n=e.TRCImpl=e.TRCImpl||{};n.global=n.global||{},e.__trcError=e.__trcError||function e(){}}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t){var n="taboola global",r="trctestcookie";function i(){for(var e="trc_cookie_storage",n=new Object,r=document.cookie.split(/;\s+/),i=0;i0?1:-1,i=new Date((new Date).getTime()+365*r*864e5),document.cookie=e+"="+escape(t.join("|"))+";path=/;expires="+i.toUTCString()}return this.getValue=function(e){return n.hasOwnProperty(e)?n[e]:null},this.setValue=function(e,t){n[e]=t,l()},this.removeKey=function(e){delete n[e],l()},this}function o(e){var t=e||{};return this.getValue=function(e){return t[e]?t[e]:null},this.setValue=function(e,n){t[e]=n},this.removeKey=function(e){delete t[e]},this.getData=function(){return t},this}function s(t){return this.getValue=function(n){return e[t+"Storage"].getItem(n)},this.setValue=function(n,r){try{e[t+"Storage"].setItem(n,r)}catch(e){}},this.removeKey=function(n){try{e[t+"Storage"].removeItem(n)}catch(e){}},this}function a(t){var n=e[t+"Storage"],r=(new Date).getTime()+"",i="_taboolaStorageDetection";try{if(n.setItem(i,r),n.getItem(i)==r)return n.removeItem(i),n}catch(e){}return null}function c(n){try{if(e.localStorage instanceof Storage&&t.useStorageDetection&&a(n))return new s(n)}catch(e){return null}}var u=function r(){return this.state={},this.getLocalStorageImplementation=function(t,n){if(null!=this.state.privateStorageImpl&&"strict-w3c-storage"!=t)return this.state.privateStorageImpl;var r=e.TRCImpl?e.TRCImpl.global:{};switch(t=t||(r["local-storage-usage"]?r["local-storage-usage"]:"prefer-w3c-storage")){case"strict-w3c-storage":return c("session"===n?"session":"local");case"prefer-w3c-storage":var s=c("local");if(s)return this.state.privateStorageImpl=s;case"prefer-cookies":try{if(this.canWriteCookies())return this.state.privateStorageImpl=new i}catch(e){}default:return this.state.privateStorageImpl=new o}},this.getFirstPartyCookie=function(){if(this.state.firstPartyCookie)return this.state.firstPartyCookie;var e=this.getLocalStorageImplementation();if(e instanceof i||e instanceof o)return this.state.firstPartyCookie=e;try{if(this.canWriteCookies())return this.state.firstPartyCookie=new i}catch(e){}return this.state.firstPartyCookie=new o},this.canWriteCookies=function(){return e.navigator.cookieEnabled},this.getDummyStorage=function(e){return new o(e)},this.getValue=function(e){return this.getPublisherValue(n,e)},this.storePublisherValue=function(e,t,n){var r;this.isNotAllowedToWriteValue(t,n)||(r=this.buildKeyWithPublisher(e,t),this.getLocalStorageImplementation().setValue(r,n),this.addKeyToStoredKeysList(r))},this.isNotAllowedToWriteValue=function(e,n){return null==n||void 0==n||t.doNotTrack&&!this.isAllowedKeyWhenDoNotTrack(e)},this.buildKeyWithPublisher=function(e,t){return e+":"+t},this.getPublisherValue=function(e,n){return t.doNotTrack&&!this.isAllowedKeyWhenDoNotTrack(n)?null:this.getLocalStorageImplementation().getValue(this.buildKeyWithPublisher(e,n))},this.addKeyToStoredKeysList=function(e){var t=this.getStoredKeysList();-1===t.indexOf(e)&&(t.push(e),this.setStoredKeysList(t))},this.getStoredKeysList=function(){var e=this.buildKeyWithPublisher(n,"local-storage-keys"),t=this.getLocalStorageImplementation().getValue(e),r=[];try{r=JSON.parse(t)||[]}catch(e){__trcError("Could not parse local storage keys",e)}return r},this.setStoredKeysList=function(e){var t,r;try{t=JSON.stringify(e),r=this.buildKeyWithPublisher(n,"local-storage-keys"),this.getLocalStorageImplementation().setValue(r,t)}catch(e){__trcError("Could not stringify local storage keys",e)}},this.isAllowedKeyWhenDoNotTrack=function(t){var n,r=(e.TRCImpl&&e.TRCImpl.global||{})["dnt-allowed-keys"]||["session-id"],i;return null!==t&&void 0!==t&&(i=t.split(":")[1]||t,-1!==r.indexOf(i))},this.storeUserId=function(e){this.isNotAllowedToWriteValue("user-id",e)||this.storePublisherValue(n,"user-id",e)},this.getUserIdFirstPartyCookie=function(){return this.getFirstPartyCookie().getValue(this.buildKeyWithPublisher(n,"user-id"))},this.getSessionDataFirstPartyCookie=function(){return this.getFirstPartyCookie().getValue(this.buildKeyWithPublisher(n,"session-data"))},this.initState=function(){void 0===this.state&&(this.state={}),this.state.privateStorageImpl=null},this.initState(),this};t.tfaPageManager=t.tfaPageManager||new u,t.tfaPageManager.TABOOLA_GLOBAL_KEY=n}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t,n){var r=n.tfaPageManager,i="https://",o="tblci",s="TABOOLA-DO-NOT-TRACK",a="#"+o;function c(e,t){e&&t&&(t[e]=!0)}function u(e,t,n){for(var r={},i=0;i1}n.tfaUserId={initialized:!1,userId:null,clickId:null,getUserId:function e(){return this.userId},getClickId:function e(){return this.clickId},getHttpsPrefix:function e(){return i},sendUserIdsToTrc:function t(r,i,o,s){var a,c='https:',l=[];if(u(r,i,o))return n.tfaUtil.safeAddParam("uiref",r,l),n.tfaUtil.safeAddParam("uils",i,l),n.tfaUtil.safeAddParam("uifpc",o,l),n.tfaUtil.safeAddParam("tblci",s,l),a=new Image,e._tfa.config.safeGet("tfa:add-referrer-policy-when-firing-pixel",!0)&&(a.referrerPolicy="no-referrer-when-downgrade"),a.src=c+"//trc.taboola.com/sg/taboola-tfa/1/um/?"+l.join("&"),a},isUserCanBeTracked:function t(n){return!n||!e._tfa.config.safeGet("tfa-uid:filter-do-not-track",!0)||-1===n.indexOf(s)},readAndStoreUserId:function e(){var t=this.extractUserIdFromReferrer(),n=r.getValue("user-id"),i=r.getUserIdFirstPartyCookie();this.isUserCanBeTracked(t)||(t=void 0),this.isUserCanBeTracked(n)||(n=void 0),this.isUserCanBeTracked(i)||(i=void 0),this.sendUserIdsToTrc(t,n,i,this.getClickId()),t&&(r.storeUserId(t),i&&r.getFirstPartyCookie().setValue(r.TABOOLA_GLOBAL_KEY+":"+"user-id",t)),this.userId=t||n||i},readAndStoreClickIdParam:function e(){var t=this.extractClickIdFromUrl(this.getWindowLocation().toString())||this.extractClickIdFromUrl(this.getReferrer()),n=r.getValue(o);t&&r.storePublisherValue(r.TABOOLA_GLOBAL_KEY,o,t),this.clickId=t||n},extractUserIdFromReferrer:function e(){var t=this.getReferrer();if(t&&t.indexOf("taboola")>-1)return n.tfaUtil.getParameterByName("ui",t)},extractClickIdFromUrl:function e(t){if(t){var r=t.length>1&&-1!==t.indexOf("#")?t.substring(t.indexOf("#")):"",i;if(i=n.tfaUtil.getParameterByName(o,t))return i;if(r&&r.length>a.length&&0===r.indexOf(a))return r.substr(a.length)}},getWindowLocation:function t(){return e.location},getReferrer:function e(){return t.referrer},init:function e(){this.initialized||(this.readAndStoreUserId(),this.readAndStoreClickIdParam(),this.initialized=!0)}},n.tfaUserId.init(),n.tfaUserId.CLICK_ID_KEY=o}(window,document,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t){var n="_tfa",r=e[n]=e[n]||[],i,o,s,a,c=6*60*60*1e3,u="eng_mt",l="crossSessionsData",f=36,d;function h(e,t,n){var r=this.getTimeLeftForSession(e,this.getSessionDuration(),t);r<0&&(r=0),setTimeout(function(){n()},r)}function g(e){return e.ver&&e.ver===this.getDataVersion()}var p=function e(){};p.prototype={constructor:p,init:function e(n){if(d=r.config.safeGet("tfa:engagement:session-duration-in-milliseconds",c),!this.isInitialized()){var i=t.eventUtils.getDateNow(),o=this.getSessionDataFromStorage();if(this.getIsLocalStorageAvailable())return s=o&&o.sessionStartTime,h.call(this,o,i,n),s&&!this.isSessionInvalid(o)||(s=i,this.persistDefaultValues(s)),a=!0,this}},getStorageKey:function e(){return u},getCrossSessionsData:function e(t){var n=t&&t.getValue(this.getStorageKey()),r=n&&JSON.parse(n);return r&&r[l]},resetStorageMetricData:function e(){var n=t.tfaPageManager.getLocalStorageImplementation("strict-w3c-storage"),r=this.getCrossSessionsData(n),i={crossSessionsData:r};n.setValue(this.getStorageKey(),r?JSON.stringify(i):"")},hasOnlyCrossSessionData:function e(t,n){return t&&1===t.length&&n.hasOwnProperty(l)},isSessionInvalid:function e(t){if(!t)return!0;var n=Object.keys(t);return this.hasOnlyCrossSessionData(n,t)},getSessionDataFromStorage:function e(){var n,r;n=t.tfaPageManager.getLocalStorageImplementation("strict-w3c-storage"),o=!!n;var i=n&&n.getValue(this.getStorageKey());if(r=i&&JSON.parse(i))return this.isSessionInvalid(r)?r:!g.call(this,r)||this.hasSessionEnded()?(this.resetStorageMetricData(),r):r},hasSessionEnded:function e(){return!!a&&(!s||t.eventUtils.getDateNow()-s>this.getSessionDuration())},persistDefaultValues:function e(n){var r=t.tfaPageManager.getLocalStorageImplementation("strict-w3c-storage");if(r){var i={ver:f,sessionStartTime:n,scrollDepth:0,sessionDepth:[],timeOnSite:0},o=this.getCrossSessionsData(r);o&&(i[l]=o),r.setValue(this.getStorageKey(),JSON.stringify(i))}},persistSpecificMetricsData:function e(n,r){var i=t.tfaPageManager.getLocalStorageImplementation("strict-w3c-storage"),o;i&&n&&(o=this.getSessionDataFromStorage())&&(o[n]=r,i.setValue(this.getStorageKey(),JSON.stringify(o)))},getCrossSessionsDataKey:function e(){return l},getSessionDuration:function e(){return d},getDataVersion:function e(){return f},getIsLocalStorageAvailable:function e(){return o},getSessionStartTime:function e(){return s},getTimeLeftForSession:function e(t,n,r){return t&&s?s+n-r:n},isInitialized:function e(){return a}},(i=r.TEM=r.TEM||{}).ESU=i.ESU||new p}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t){var n="_tfa",r;function i(e,t){this.storageUtils.persistSpecificMetricsData(e,t)}var o=function e(){};o.prototype={constructor:o,init:function e(t,n,r){this.isValid=t&&n&&r,this.storageUtils=t,this.visibilityListener=r,this.refreshFromStorage(),this.initLastVisibleStartTime(),this.visibilityListener.subscribeToEvent(this.handleVisibilityChange.bind(this)),n.subscribeToEvent(this.handleStorageChange.bind(this))},getStorageKey:function e(){return"timeOnSite"},initLastVisibleStartTime:function e(){this.isValid&&(this.lastVisibleStartTime=t.eventUtils.getDateNow())},refreshFromStorage:function e(){if(this.isValid){var t=this.storageUtils.getSessionDataFromStorage(),n=0;t&&t[this.getStorageKey()]&&(n=t[this.getStorageKey()]||0),this.timeOnSite=n}},calcTimeOnSite:function e(){if(this.isValid)return this.lastVisibleStartTime?this.timeOnSite+(t.eventUtils.getDateNow()-this.lastVisibleStartTime):this.timeOnSite},handleVisibilityChange:function e(){this.isValid&&(this.visibilityListener.getIsPageHidden()?(this.timeOnSite=this.calcTimeOnSite(),i.call(this,this.getStorageKey(),this.timeOnSite)):this.lastVisibleStartTime=t.eventUtils.getDateNow())},handleStorageChange:function e(){this.refreshFromStorage()},getTimeOnSite:function e(){if(this.isValid)return this.visibilityListener.getIsPageHidden()?this.timeOnSite:this.calcTimeOnSite()}},(r=e[n]=e[n]||[]).TEM=r.TEM||{},r.TEM.TOS=r.TEM.TOS||new o}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(){var e="_tfa",t,n=!1,r;function i(){return void 0==document.body||void 0==document.documentElement?0:(n=!0,Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight)-document.documentElement.clientHeight);var e}function o(e,t){this.storageUtils.persistSpecificMetricsData(e,t)}function s(e,t){var n;return function(){var r=this,i=arguments;clearTimeout(n),n=setTimeout(function(){e.apply(r,i)},t)}}var a=function e(){};a.prototype={constructor:a,init:function e(t,n){this.storageUtils=t||{},n.subscribeToEvent(this.handleStorageChange.bind(this)),this.refreshFromStorage(),this.initEventListeners(),this.updateMeasurements(),this.calcMaxScrollPercentage()},getStorageKey:function e(){return"scrollDepth"},getScrollDepth:function e(){return n||this.calcMaxScrollPercentage(),this.maxScrollPercentage},getMaxScrollableAmount:function e(){return n||(this.maxScrollableAmount=i()),this.maxScrollableAmount},initEventListeners:function e(){window.addEventListener("resize",s(this.onResize.bind(this),100)),window.addEventListener("scroll",s(this.onScroll.bind(this),50))},refreshFromStorage:function e(){var t=this.storageUtils.getSessionDataFromStorage(),n=0;t&&t[this.getStorageKey()]&&(n=t[this.getStorageKey()]||0),this.maxScrollPercentage=n},onResize:function e(){this.updateMeasurements()},onScroll:function e(){this.calcMaxScrollPercentage()},updateMeasurements:function e(){this.winHeight=window.innerHeight,this.maxScrollableAmount=i()},calcMaxScrollPercentage:function e(){this.updateMeasurements();var t=0===this.maxScrollableAmount?0:Math.floor(window.pageYOffset/this.maxScrollableAmount*100);t>this.maxScrollPercentage&&(this.maxScrollPercentage=t,o.call(this,this.getStorageKey(),this.maxScrollPercentage))},handleStorageChange:function e(){this.refreshFromStorage()}},(r=(t=window[e]=window[e]||[]).TEM=t.TEM||{}).SCD=r.SCD||new a}(),function(e,t){var n,r,i=e["_tfa"].TEM,o=function e(){};o.prototype={constructor:o,init:function e(n,r,i){this.storageUtils=n,this.refreshFromStorage(),t.eventUtils.safeAddEventListener(i,this.handleUnipPageView.bind(this)),r.subscribeToEvent(this.handleStorageChange.bind(this))},getKey:function e(){return"ssd"},getStorageKey:function e(){return"sessionDepth"},setState:function e(t){this.visitedUrls={};for(var n=0;n=0?"TRC":'TFASC']),function(e){var t,n=e["_tfa"]||[],r=n.TEM||{},i=30*24*60*60*1e3,o=10,s="tfa:engagement:session-history-timeframe-in-milliseconds",a="tfa:engagement:session-history-limit",c="sessionsHistory",u,l,f=function e(){};f.prototype={init:function e(t){u=n.config.safeGet(a,o),l=n.config.safeGet(s,i),this.storageUtils=t,this.updateCrossSessionsData(this.storageUtils.getSessionStartTime())},updateCrossSessionsData:function e(t){var n=this.updateData(t);return this.storageUtils.persistSpecificMetricsData(this.storageUtils.getCrossSessionsDataKey(),n),n},updateData:function e(t){var n=this.getCrossSessionsDataFromStorage()||{};return n[c]=this.getSessionsHistory(t),n},resetCrossSessionsData:function e(){this.storageUtils.persistSpecificMetricsData(this.storageUtils.getCrossSessionsDataKey(),"")},getCrossSessionsDataFromStorage:function e(){var t=this.storageUtils.getSessionDataFromStorage();return t&&t[this.storageUtils.getCrossSessionsDataKey()]},getFilteredSessionsHistory:function e(t,n){var r=t?this.removeOldSessions(t,n):[];if(!r.indexOf(n)>-1&&!this.isInPreviousSession(r,n)){for(;r.length>u-1;)r.shift();r.push(n)}return r},removeOldSessions:function e(t,n){for(var r=[],i=0;it},getSessionsHistory:function e(t){var n=this.getCrossSessionsDataFromStorage(),r=n?n[c]:[];return this.getFilteredSessionsHistory(r,t)},isInPreviousSession:function e(t,n){return!(!Array.isArray(t)||!t.length)&&n-t[t.length-1]=0?"TRC":'TFASC']),function(e,t){var n="_tfa",r,i=function e(){};i.prototype={constructor:i,init:function e(t){this.runningId=0,this.subscribers={},this.storageUtils=t,this.initListener()},initListener:function e(){t.eventUtils.safeAddEventListenerToWindow("storage",this.handleStorageChange.bind(this))},handleStorageChange:function e(t){t&&t.key===this.storageUtils.getStorageKey()&&this.notify(t)},subscribeToEvent:function e(t){var n=this.runningId++;return this.subscribers[n]=t,function(){delete this.subscribers[n]}.bind(this)},notify:function e(t){Object.keys(this.subscribers).forEach(function(e){this.subscribers[e](t)}.bind(this))}},(r=e[n]=e[n]||[]).TEM=r.TEM||{},r.TEM.storageListener=r.TEM.storageListener||new i}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC']),function(e,t){var n="_tfa",r=e[n]=e[n]||[],i,o=r.TEM=r.TEM||{},s=o.ESU||{},a=o.SCD||{},c=o.SSD||{},u=o.TOS||{},l=o.returnVisits||{},f=o.crossSessionsUtils||{},d=o.visibilityListener||{},h=o.storageListener||{},g=1500,p=50,v=3e4,m="numOfTimesMetricsSent",S="pre_d_eng_tb",b={SESSION_END:"SESSION_END"},y,I,E=!1,T=Date.now();function w(e,t){var n=u.getTimeOnSite(),r=a.getScrollDepth(),i=c.getMetric(),o={notify:"event",name:S,tos:n,scd:r,ssd:i,est:s.getSessionStartTime(),ver:s.getDataVersion(),isls:s.getIsLocalStorageAvailable(),src:e,invt:t,msa:"function"==typeof a.getMaxScrollableAmount?a.getMaxScrollableAmount():void 0};return o=l.addReturnVisits(o)}function C(e,t){var n=w(e,t);n.est&&(i.pageViewAccountIds?R(i.pageViewAccountIds,n):k(n))}function R(e,t){var n=Object.keys(e);n.length>0?n.forEach(function(n){t.id=e[n],k(t)}):k(t)}function k(e){i.push(e)}function _(){O(),s.resetStorageMetricData()}function O(){clearTimeout(I)}function U(e){(isNaN(y)||y<0)&&(y=0),s.hasSessionEnded()||(y++,s.persistSpecificMetricsData(m,y),P()||o.sendMetrics("i",e),D())}function P(){return u.getTimeOnSite()>5*60*1e3&&c.getMetric()>5}function D(){if(clearTimeout(I),E&&!d.getIsPageHidden()){var e=g*Math.pow(2,y);e!==1/0&&(I=setTimeout(U,e,e))}}function A(){N(),D()}function N(){var e=s.getSessionDataFromStorage();y=e&&e[m]&&e[m]||0}function x(){h.subscribeToEvent(L.bind(this)),d.subscribeToEvent(M.bind(this))}function M(){d.getIsPageHidden()?O():D()}function L(e){function t(e){var t=JSON.parse(e.newValue),i=JSON.parse(e.oldValue);return!n(t,i)&&!r(t,i)}function n(e,t){return e.sessionDepth.length!==t.sessionDepth.length}function r(e,t){return e.timeOnSite!==t.timeOnSite}N(),e&&E&&!d.getIsPageHidden()&&t(e)&&(E=!1,O(),V(p,v,A,O))}function V(e,t,n,r){var i=!1;function o(e){if(window.top!==window){var t=window.parent;for(t.postMessage(e,"*");t!==t.parent;)(t=t.parent).postMessage(e,"*")}function n(t){try{for(var r=0;r=0?"TRC":'TFASC']),function(e,t){var n="_tfa",r=e[n]=e[n]||[],i="taboola global:last-external-referrer",o="taboola",s="other",a=["taboola","taboolanews","taboolasyndication"];t.lastExternalReferrer={init:function e(){r.config.safeGet("tfa:last-external-referrer:is-disabled",!1,1231667)||this.extractExternalReferrerIfExistsAndStoreLocally()},extractExternalReferrerIfExistsAndStoreLocally:function t(){var n=this.extractExternalReferrer(e);n&&this.saveExternalReferrerToLocalStorage(n)},extractExternalReferrer:function e(n){var r=n.location.href,i=this.getExternalReferrer(n);return this.isExternalReferrerTaboola(r,i)?o:i||t.tfaUtil.getParameterByName("utm_source",r)||t.tfaUtil.getParameterByName("gclid",r)||t.tfaUtil.getParameterByName("fbclid",r)||t.tfaUtil.getParameterByName("dicbo",r)||t.tfaUtil.getParameterByName("dclid",r)?s:""},isExternalReferrerTaboola:function e(n,r){if(t.tfaUtil.getParameterByName("tblci",n))return!0;var i=t.tfaUtil.getParameterByName("utm_source",n);if(i&&"taboola"===i.toLowerCase())return!0;if(r)for(var o=r.split("/")[2],s=0;s=0?"TRC":'TFASC']),function(e,t,n){var r=t.tfaPageManager||{},i="_tfa",o=window[i]=window[i]||[],s=o.TEM||{},a={event:re,subscription:oe},c=/(\S+)taboola(\S+|)\.com\/libtrc\/unip\/(\S+)\/tfa\.js(\S+|)/,u="script[src$='tfa.js']",l="//",f="page_view",d=["notify","id"],h={name:"en",url:"item-url",referrer:"ref",timestamp:"tim"},g=-1,p={protocol:'https:',host:"trc.taboola.com",httpMethod:"get",loggerEventName:"unip",logToConsole:!0},v={EMPTY_COMMAND:"EMPTY_COMMAND",MISSING_NOTIFY:"MISSING_NOTIFY",INVALID_NOTIFY:"INVALID_NOTIFY",MISSING_NAME:"MISSING_NAME",INVALID_ID:"INVALID_ID"},m={TFA_VALIDATION_ERROR:"TFA_VALIDATION_ERROR"},S=((T={})[f]=ae,T),b=function(){var e={};return e[t.sharedEvents.REQUEST_ID_CREATION_TIMEOUT]="to",e[t.sharedEvents.REQUEST_ID_CREATION_ERROR]="err",e[t.sharedEvents.REQUEST_ID_CREATION_JS_ERROR]="jserr",e[t.sharedEvents.INVALID_TRK_RESPONSE]="itrkr",e}(),y=!isNaN(parseFloat(1231667)),I="callback",E="ler",T;function w(){var e=ue();e.initialized&&e.domAccountId&&setTimeout(function(){for(var e=ue().asyncQueue;e.length;)le(e.shift())},0)}function C(){var e=R(),t;if(e&&e.src&&(t=e.src.replace(c,"$3")))return/^\d+$/.test(t)?parseInt(t,10):(de("Value '"+t+"' is invalid for 'id' param in script source url '"+e.src+"'. Only numeric values are allowed."),g)}function R(){for(var e=document.querySelectorAll(u),t,n=0;n0)return t}function k(){return t.eventUtils.getDateNow()}function _(e){e["ce"]="subscr"}function O(e){var t=r.getSessionDataFirstPartyCookie();void 0!==t&&t&&(e["sd"]=t)}function U(e){var t=P();t&&(e["ui"]=t)}function P(){try{var e=t.tfaUserId.getUserId(),n=r.getValue("user-id");if(e||n)return e||n}catch(e){de("Error while trying to add user-id param",e)}}function D(e){try{var n=t.tfaUserId.getClickId();n&&(e[t.tfaUserId.CLICK_ID_KEY]=n)}catch(t){de("Error while trying to addClickIdParam, params="+JSON.stringify(e),t)}}function A(e){var n=ue();n.referrer||(n.referrer=t.trk.getReferrer()),e[h.referrer]=n.referrer}function N(e,t){var n=h.url,r;Ie(pe(e),t)&&(e[n]=e[n]||document.location.href)}function x(e){var t={},n=!1,r;for(var i in e[h.timestamp]=k(),e)!e.hasOwnProperty(i)||d.indexOf(i)>=0||(t[r=h.hasOwnProperty(i)?h[i]:i]=e[i],n=!0);return n&&t}function M(e,t){B(t),V(e,t)}function L(e){document.featurePolicy&&document.featurePolicy.allowedFeatures()&&-1!==document.featurePolicy.allowedFeatures().indexOf("attribution-reporting")&&(e.headers||(e.headers={}),e.headers["Attribution-Reporting-Eligible"]="trigger")}function V(e,n){var r=ve(e)+l+me(e,n);z(n,e),j(n,e),L(n);try{t.TRCLogger[p.httpMethod](r,p.loggerEventName,n,e)}catch(t){de("Error while trying to send to server event with id '"+e+"' and params '"+JSON.stringify(n)+"'.",t)}}function B(e){var t=P(),n=e[I];if(n){if(!t)return he("No UserId to notify callback"),void delete e[I];if("function"!=typeof n)return he("Callback function parameter is not a function "+n),void delete e[I];try{n({userId:t})}catch(e){de("Error calling advertiser callback",e)}delete e[I]}}function j(e,t){U(e),D(e),A(e),ee(e),N(e,t),$(e),K(e),W(e,t),F(e,t)}function K(e){var n=t.lastExternalReferrer.getLastExternalReferrer();n&&(e[E]=n)}function F(e,n){var r;o.config.safeGet("unip:collect-cookie-banner-consent:enabled",!0,n)&&(r=t.trk.parseCookieBanner())&&(e.cbp=r.cookieBannerProvider.providerName,e.cbpv=r.cookieBannerProvider.version,r.cookieBannerConsent.tcString&&o.config.safeGet("unip:send-tc-string:enabled",!0,n)?(e.tcs=r.cookieBannerConsent.tcString,void 0!==r.cookieBannerConsent.gdprApplies&&(e.ga=r.cookieBannerConsent.gdprApplies),void 0!==r.cookieBannerConsent.cmpStatus&&(e.cmps=r.cookieBannerConsent.cmpStatus)):r.cookieBannerConsent.consentData&&(e.cbcd=r.cookieBannerConsent.consentData))}function $(e){e&&s&&s.ESU&&s.ESU.getIsLocalStorageAvailable()&&(G(e),q(e),H(e))}function G(e){s.TOS&&(e.tos=s.TOS.getTimeOnSite())}function q(e){if(s.SSD){var n=s.SSD.getMetric(),r=t.eventUtils.hashString(window.location.href);s.SSD.isURLVisited(r)||n++,e.ssd=n}}function H(e){s.SCD&&(e.scd=s.SCD.getScrollDepth())}function W(e,n){o.config.safeGet("unip:add-ccpa-params",!0,n)&&t.trk.getCcpaParam(function(t){t&&(e["ccpaPs"]=t)})}function z(e,t){Q(e),Y(e,t),Z(e,t)}function J(e,t){_(t),O(t),ie(e,t)}function Q(e){e["vi"]=t.trk.getViewId()}function Y(e,n){var r=t.trk.getPublisherRequestId(n);r&&(e["ri"]=r)}function Z(e,n){var r=t.trk.getPublisherSessionData(n);r&&(e["sd"]=r)}function X(e,t){e["mrir"]=t}function ee(e){e["cv"]=n}function te(e,t){if(e===f)for(var n in t)if(!([h.name,h.timestamp].indexOf(n)>=0))return!0;return!1}function ne(e,n){var r=ue(),i;if(!t.trk.getPublisherRequestId(e)){if(t.trk.isRequestProcessing(e))return void r.messageDelayer.delayMessage(e,n,{successCallback:M,failCallback:function e(t,n,r,i){var o=b[i];o||(o=i),X(n,o),V(t,n)},timeoutInMillis:ge(e)});X(n,t.trk.getRequestStatus(e))}V(e,n)}function re(e,n){var r=x(e),i=pe(r),o=S[i];if(n=parseInt(n,10),!o||!o(r,n)){if(be(n)){if(ye(n))return void ne(n,r);t.trk.getPublisherRequestId(n)||X(r,"wffo")}else X(r,"ttd");V(n,r)}}function ie(e,t){void 0!==e["sourceurl"]&&e["sourceurl"]&&(t["surl"]=e["sourceurl"])}function oe(e,t){var n=x(e);J(e,n),V(parseInt(t,10),n)}function se(e,n){var r=!1;try{r=!!t.tfaUserId.getClickId()}catch(e){}return Se(n)&&!te(f,e)&&!r}function ae(e,n){var r=ue(),i=!1;return n&&(i=se(e,n),j(e),r.pageViewAccountIds[n]=parseInt(n,10),t.eventUtils.dispatchEvent(t.sharedEvents.PAGE_VIEW,{accountId:n,publisherIdType:t.publisherIdType.ID,pageViewInitiator:t.pageViewInitiator.TFA,isUnifiedPageView:i,metadata:e})),i}function ce(e){return e?e.notify?a.hasOwnProperty(e.notify)?e.name?!(e.hasOwnProperty("id")&&!/^\d+$/.test(e.id))||(fe(v.INVALID_ID,e,"Value '"+e.id+"' is invalid for 'id' field in command '"+JSON.stringify(e)+"'. Only numeric values are allowed."),!1):(fe(v.MISSING_NAME,e,"Mandatory 'name' field is missing in command '"+JSON.stringify(e)+"'."),!1):(fe(v.INVALID_NOTIFY,e,"Value '"+e.notify+"' is invalid for 'notify' field in command '"+JSON.stringify(e)+"'."),!1):(fe(v.MISSING_NOTIFY,e,"Mandatory 'notify' field is missing in command '"+JSON.stringify(e)+"'."),!1):(fe(v.EMPTY_COMMAND,e,"Command is '"+e+"'."),!1)}function ue(){return window&&window[i]&&window[i].TUP||{}}function le(e){var t,n;if(ce(e))if(t=ue(),n=e.id||t.domAccountId){if(n!==g)try{a[e.notify](e,n)}catch(t){de("An error occurred while handling command '"+JSON.stringify(e)+"'.",t)}}else t.asyncQueue.push(e)}function fe(e,n,r){var i=ue();t.eventUtils.dispatchEvent(m.TFA_VALIDATION_ERROR,{accountId:i.domAccountId,errorCode:e,command:n}),de(r)}function de(e,t){p.logToConsole&&he(e,t)}function he(e,t){t?console.log("Taboola Pixel: "+e,t):console.log("Taboola Pixel: "+e)}function ge(e){return 500+o.config.safeGet("tfa:trk:tracking-request-timeout",2e3,e)}function pe(e){return e[h.name]}function ve(e){return o.config.safeGet("tfa:default-protocol",p.protocol,e)}function me(e,t){var n=pe(t),r;return o.config.safeGet("tfa:event-host-map",{},e)[n]||p.host}function Se(e){return be(e)&&o.config.safeGet("tfa:trk:is-unified-page-view",!1,e)}function be(e){return o.config.safeGet("tfa:trk:enabled",!0,e)}function ye(e){return o.config.safeGet("tfa:trk:wait-for-request-id",!0,e)}function Ie(e,t){var n=o.config.safeGet("tfa:add-item-url:event-list",[],t);return"*"===n||n.indexOf(e)>=0}function Ee(){var e=o.TUP=o.TUP||{},n=o.config.safeGet("tfa:get-publisher-id-from-baker",!1);e.domAccountId=e.domAccountId||(n&&y?1231667:C()),e.initialized||(e.push=o.TUP.push||le,e.initialized=!0,e.asyncQueue=[],e.EVENTS=m,e.pageViewAccountIds={},e.messageDelayer=new t.MessageDelayer("publisherId",t.sharedEvents.REQUEST_ID_CREATED,[t.sharedEvents.REQUEST_ID_CREATION_JS_ERROR,t.sharedEvents.REQUEST_ID_CREATION_ERROR,t.sharedEvents.REQUEST_ID_CREATION_TIMEOUT,t.sharedEvents.INVALID_TRK_RESPONSE]),s&&s.init&&s.init()),w()}Ee()}(window,window['TFASC'.indexOf("{jsScope}")>=0?"TRC":'TFASC'],"20231130-4-RELEASE"),function(e,t,n){var r="_tfa",i,o={orderid:"orderid",currency:"currency",revenue:"revenue",quantity:"quantity",name:"name",attributionGroup:"attributionGroup"},s={type:"marking-type"},a='https:'+"//trc.taboola.com/{$publishreId}log/3/{$logType}?",c=/(\S+)taboola(\S+|)\.com\/libtrc\/(\S+)\/tfa\.js(\S+|)/,u="unip/",l=[],f=[],d="_tecq",h="_dcojobs",g=!isNaN(parseFloat(1231667));function p(e){var t;switch(e.notify){case"action":t=l;break;case"mark":t=f;break;case"event":case"subscription":t=i.TUP;break;case"ecevent":var n=i.config&&i.config.safeGet("tfa:ecomm:enabled",!1,e.id),r=i.config&&i.config.safeGet("tfa:ecomm:cnx-enabled",!1,e.id);n||r?t=window[d]=window[d]||[]:i.config&&i.config.safeGet("tfa:dco:jobs:enabled",!1,e.id)&&(t=window[h]=window[h]||[]);break;default:return}t&&t.push(e)}function v(){return n.tfaUserId&&n.tfaUserId.getUserId()?"&ui="+encodeURIComponent(n.tfaUserId.getUserId()):""}function m(){return n.tfaUserId&&n.tfaUserId.getClickId()?"&"+n.tfaUserId.CLICK_ID_KEY+"="+encodeURIComponent(n.tfaUserId.getClickId()):""}function S(){var t,n,r,i;if(r=e._tfa.config.safeGet("tfa:get-publisher-id-from-baker",!1)&&g?1231667:R())for(t=0,n=l.length;t=0?"TRC":'TFASC']);