{"status":"OK","geo":"US","deviceDetected":1,"fiViewerId":"e8245cc1829b5fbaf57f5c604d87dff7","pageViewUniqueId":4287816873452098,"datasource":"LIVE","options":{"cmp_enableintegration":true,"amp":{"initialMinSpacing":0.9,"initialMinSpacingUnits":"vp"},"hb_analytics":true,"has_blocked_urls":true,"has_blocked_urls_slashend":"onlyNonSlashEnd","has_blocked_urls_withparams":"both","notHotDog":{"enabled":false,"selectors":[]},"siteLang":"he","campaignLimitations":{},"eventTracking":{"trackingDomains":[{"host":"cdn.firstimpression.io","type":"full"}],"trackScroll":1,"trackTimeOnPage":1,"probability":12,"cookiename":"fitracking"},"prependScript":"if( (new Date() - new Date(FI.options.builtOn)) \/ (1000*60*60) > 24 ) {\n    if(!window.fi_reloaded) { window.fi_reloaded=true;\n    \tfetch(\"https:\/\/\" + FI.options.ecdnDomain + \"\/fi_client.js\",  {cache: \"reload\"}).then(()=>{ \t\t\n    \t    clearTimeout(FI.g_clientManager.appendLoopTimeout);\n    \t\tvar body = document.getElementsByTagName(\"head\")[0];\n                newdiv = document.createElement(\"script\");\n    \t\t    newdiv.setAttribute(\"type\", \"text\/javascript\");\n    \t\t    newdiv.setAttribute(\"src\", \"https:\/\/\" + FI.options.ecdnDomain + \"\/fi_client.js\");    \n    \t    delete FI; delete fipb; delete fiQuery;\n    \t    body.appendChild(newdiv);\n    \t\tthrow (\"Cache problem!\");\n    \t});\n    \treturn;\n    }\n}\n\/*{trackingcode|cookiename:fitracking}*\/\nfiQuery.expr[\":\"].hasDirectTextNode = fiQuery.expr.createPseudo(function(a) { \n    var wordCount = a || 10;\n    return function(c) { \n        if (c.tagName != \"IFRAME\" && fiQuery(c).contents().filter(function() { return this.nodeType == 3 && this.textContent.split(' ').length >= wordCount; }).length == 1) \n                return c;\n    }\n});\nfiQuery.expr[\":\"].distanceFromElement = fiQuery.expr.createPseudo(function(a) { \n    var c = a.split(\/\\,(?=\\d)|\\,(?=\\s\\d)|\\,(?=false)|\\,(?=\\sfalse)|\\,![^\\(]*\\)\/g)\n      , f = fiQuery();\n    c[2] && (c[2] = c[2].trim());\n    return function(l) {\n        f.length && \"false\" != c[2] || (f = fiQuery(c[0]));\n        var n = parseInt(c[1]);\n        l = fiQuery(l);\n        var y = !0;\n        if (f.length) {\n            var C = l.offset()\n              , I = l.height();\n            f.each(function(H) {\n                var O = f.eq(H)\n                  , V = O.offset();\n                H = V.top - n;\n                O = V.top + O.height() + n;\n                y = C.top > O || C.top + I < H;\n                if (!y)\n                    return !1\n            })\n        }\n        return y\n    }\n});\nfiQuery(window).on('SPCReturned', function () {\n    FI.state.utils = fiUtils = {\n        getPlacementsPerCond: function (...cond) {\n            var count = 0;\n            return fiQuery.map(FI.g_clientManager.placementQueue, function ($placement) {\n                count = 0;\n                for (let i = 0; i < cond.length; i++) {\n                    if (fiUtils[cond[i].placement]($placement, cond[i].is)) count++;\n                }\n                if (count == cond.length) return [$placement];\n            });\n        },\n        enabledExtraOption: function ($placement, option) {\n            return (typeof $placement.options.extra != 'undefined' && typeof $placement.options.extra[option] != 'undefined' && (typeof $placement.options.extra[option].enabled != 'undefined' && $placement.options.extra[option].enabled || typeof $placement.options.extra[option].enabled == 'undefined'))\n                || (typeof $placement.options[option] != 'undefined' && (typeof $placement.options[option].enabled != 'undefined' && $placement.options[option].enabled || typeof $placement.options[option].enabled == 'undefined'));\n        },\n        enabledExtraValue: function ($placement, optionPathAndValueArr) {\n            let optionVal = optionPathAndValueArr.length - 1,\n                placementOption = typeof $placement.options.extra != 'undefined' ? $placement.options.extra : $placement.options,\n                optionNotFound = false;\n            for (var i = 0; i <= optionPathAndValueArr.length - 2; i++) {\n                if (typeof placementOption[optionPathAndValueArr[i]] != \"undefined\")\n                    placementOption = placementOption[optionPathAndValueArr[i]];\n                else {\n                    optionNotFound = true;\n                    break;\n                }\n            }\n            return !optionNotFound && placementOption == optionVal;\n        },\n        enabledOptionValue: function ($placement, optionPathAndValueArr) {\n            let optionVal = optionPathAndValueArr.length - 1,\n                placementOption = $placement.options,\n                optionNotFound = false;\n            for (var i = 0; i <= optionPathAndValueArr.length - 2; i++) {\n                if (typeof placementOption[optionPathAndValueArr[i]] != \"undefined\")\n                    placementOption = placementOption[optionPathAndValueArr[i]];\n                else {\n                    optionNotFound = true;\n                    break;\n                }\n            }\n            return !optionNotFound && placementOption == optionVal;\n        },\n        multiInstance: function ($placement) {\n            return $placement.options.totalRenderedInstancesLimitation > 1;\n        },\n        type: function ($placement, type) {\n            return $placement.type == type;\n        },\n        pageErrors: [],\n        getAllErrors: function (_module) {\n            let errors = [];\n            for (var i = 0; i < this.pageErrors.length; i++) {\n                if (typeof _module == \"undefined\" || this.pageErrors[i].module == _module) {\n                    this.console(this.pageErrors[i].message, \"Error\", this.pageErrors[i].module);\n                    errors.push(this.pageErrors[i]);\n                }\n            }\n            return errors;\n        },\n        console: function (message, type, _module, placementId, bannerId) {\n            FI.console.log(typeof message != \"undefined\" ? message : \"No message here.. This seems odd\",\n                typeof placementId != \"undefined\" ? placementId : '',\n                typeof bannerId != \"undefined\" ? bannerId : '',\n                typeof type != \"undefined\" ? type : 'Misc',\n                typeof _module != \"undefined\" ? _module : '')\n        },\n        pageError: function (message, _module, placement) {\n            this.pageErrors.push({ \"message\": message, \"module\": _module, \"placement\": placement });\n            this.console(message, \"Error\", _module);\n        },\n        getExtra: function ($placement) {\n            if (typeof $placement == \"object\" && typeof $placement.options != \"undefined\")\n                return typeof $placement.options.extra != \"undefined\" ? $placement.options.extra : $placement.options;\n            else if (typeof $placement == \"number\")\n                return typeof FI.g_clientManager.getPlacement($placement).options.extra != \"undefined\" ? $placement.options.extra : $placement.options;\n            else {\n                fiUtils.pageError(\"Invoking getExtra but providing ${$placement} which is not a number or an object\");\n                return { \"options\": { \"extra\": {} } }\n            }\n        },\n        getWebsiteMacro: function (macro) {\n            return macro.indexOf(\"{\") == -1 ? macro : null;\n        },\n        isLastInstance: function ($instance) {\n            return $instance.instanceId.split('_')[2] == $instance.placement.instances.length - 1;\n        },\n        getInstanceId: function ($instance) {\n            return $instance.instanceId.split(\"_\")[2];\n        },\n        isPlacementOptionEnabled: function ($instance, option) {\n            if (typeof $instance.placement.options.extra != \"undefined\")\n                return typeof $instance.placement.options.extra[option] != \"undefined\" && $instance.placement.options.extra[option][\"enabled\"];\n            return false;\n        },\n        appenndRecorderDiv: function (recorderClass) {\n            if (fiQuery(\"recorder\").length == 0) {\n                fiQuery('body').append(`<div class=recorder ${recorderClass}><\/div>`);\n            } else {\n                fiQuery(\"recorder\").addClass(`${recorderClass}`);\n            }\n        },\n        detectDeviceOrientation: function () {\n            return window.matchMedia(\"(orientation: portrait)\") ? \"portrait\" : \"landscape\";\n        },\n        getManupiliationStateByHighestValuePerPlacementType: function (arr, placementType) {\n            arr = arr.map((state, index, array) => {\n                if (typeof state != \"undefined\") return typeof fiUtils.fixed.manupiliateElementsPerPlacementType[placementType][state.name] != \"undefined\" ? state : '';\n            }).filter(elem => elem != \"\");\n\n            return arr.reduce(function (prev, current) {\n                if (typeof current != \"undefined\") return Math.abs(prev.value) > Math.abs(current.value) ? prev : current;\n                return Math.abs(prev.value);\n            });\n        },\n        setRecorder: function (update) {\n            if (fiQuery(\"div#fi_recorder\").length == 0) fiQuery('body').append('<div id=fi_recorder><\/div>');\n            if (typeof update != 'undefined') fiQuery(\"div#fi_recorder\").addClass(update);\n        },\n        getCreativeIndexByCID: function (creatives, targetCID) {\n            for (let i = 0; i < creatives.length; i++) { if (creatives[i].cid == targetCID) return i; }\n        },\n        fixed: {\n            ManipulationState: function (name, CSSKeyValuePair, selector) {\n                this.name = name;\n                \/\/ Selector not found, let's wait for it\n                if (fiQuery(selector).length == 0) {\n                    this.value = fiUtils.fixed.waitForSelector(selector, this, CSSKeyValuePair);\n                    this.selector = null;\n                    \/\/ We need to pull the value dynamically from the DOM\n                } else if (CSSKeyValuePair.property != null) {\n                    this.selector = selector;\n                    this.value = fiQuery(CSSKeyValuePair.value)[CSSKeyValuePair.property]();\n                    \/\/ Seems selector is found and value is static so let's just move on \n                } else {\n                    this.selector = selector;\n                    this.value = CSSKeyValuePair.value;\n                }\n                this.viewable = false;\n            },\n            placementsToManupiliate: [],\n            manupiliateElementsPerPlacementType: {\n                headerKick: {\n                    hide: function (value) {\n                        fiQuery('div#FIHeaderKickInner').css({ transform: `translateY(${value}px)` });\n                        fiQuery('div#FIHeaderKickAnchor').css({ transform: `translateY(${value}px)` });\n                        fiQuery(fiUtils.getWebsiteMacro(\"header:not(.open)\")).css({ transform: `translateY(0px)` });\n                    },\n                    show: function (value) {\n                        fiQuery('div#FIHeaderKickInner').css({ transform: `translateY(0px)` });\n                        fiQuery('div#FIHeaderKickAnchor').css({ transform: `translateY(0px)` });\n                        fiQuery(fiUtils.getWebsiteMacro(\"header:not(.open)\")).css({ transform: `translateY(${fiQuery('div#FIHeaderKickAnchor').height()}px)` });\n                    },\n                    close: function (value) {\n                        FI.console.log(`Resetting all manupiliations on other elements since placement was either closed or reached its end of the waterfall`, ``, ``, `fiUtils.fixed`);\n                    },\n                    navBarPush: function (valie) {\n                        fiQuery('div#FIHeaderKickInner').css({ transform: `translateY(0px)` });\n                        fiQuery('div#FIHeaderKickAnchor').css({ transform: `translateY(0px)` });\n                        fiQuery(fiUtils.getWebsiteMacro(\"header:not(.open)\")).css({ transform: `translateY(${fiQuery('div#FIHeaderKickAnchor').height()}px)` });\n                    }\n                },\n                bottomsticky: {\n                    hide: function (value) {\n                        fiQuery('div#FIBottomStickyInner').css({ transform: `translateY(${-value}px)` });\n                    },\n                    show: function (value) {\n                        fiQuery('div#FIBottomStickyInner').css({ transform: `translateY(0px)` });\n                    },\n                    cookieNoticePush: function (value) {\n                        fiQuery('div#FIBottomStickyInner').css({ transform: `translateY(${-value}px)` });\n                    },\n                    bottomBarPush: function (value) {\n                        fiQuery('div#FIBottomStickyInner').css({ transform: `translateY(${-value}px)` });\n                    }\n                },\n                outerdocked: {\n                    hide: function (value) {\n                        fiQuery('div.fi-docked').css({ zIndex: `${value}` });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(0px)` });\n                    },\n                    show: function (value) {\n                        fiQuery('div.fi-docked').css({ zIndex: 99998 });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(${value}px)` });\n                    },\n                    navBarPush: function (value) {\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ zIndex: 99998 });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(${value}px)` });\n                    }\n                },\n                docked: {\n                    hide: function (value) {\n                        fiQuery('div.fi-docked').css({ zIndex: `${value}` });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(0px)` });\n                    },\n                    show: function (value) {\n                        fiQuery('div.fi-docked').css({ zIndex: 99998 });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(${value}px)` });\n                    },\n                    navBarPush: function (value) {\n                        fiQuery('div.fi-docked').css({ zIndex: 99998 });\n                        fiQuery('div.FIOnDemandWrapper.fi-docked[style*=\"position: fixed;\"]:not([style*=\"overflow: hidden;\"]').css({ transform: `translateY(${value}px)` });\n                    }\n                },\n                hybridDocked: {\n                    initStaticStateFailSafeStyle: function () {\n                        fiQuery('body').append('<style id=\"fi-translateY-control\"> .fi-detachable-hybriddocked[style*=\"static\"] { transform: translateY(0px) !important; } <\/style>');\n                        return true;\n                    },\n                    hide: function (value) {\n                        if (fiQuery('#fi-translateY-control').length == 0) fiUtils.fixed.manupiliateElementsPerPlacementType.hybridDocked.initStaticStateFailSafeStyle();\n                        fiQuery('.fi-detachable-hybriddocked-stripe').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                        fiQuery('.fi-detachable-hybriddocked.apd_docked').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                    },\n                    navBarPush: function (value) {\n                        if (fiQuery('#fi-translateY-control').length == 0) fiUtils.fixed.manupiliateElementsPerPlacementType.hybridDocked.initStaticStateFailSafeStyle();\n                        fiQuery('.fi-detachable-hybriddocked-stripe').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                        fiQuery('.fi-detachable-hybriddocked.apd_docked').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                    },\n                    show: function (value) {\n                        if (fiQuery('#fi-translateY-control').length == 0) fiUtils.fixed.manupiliateElementsPerPlacementType.hybridDocked.initStaticStateFailSafeStyle();\n                        fiQuery('.fi-detachable-hybriddocked.apd_docked').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                        fiQuery('.fi-detachable-hybriddocked-stripe').css({ transform: `translateY(${value}px)`, transition: `all 0.1s` });\n                    }\n                }\n            },\n            waitForSelector: function (selector, state, CSSKeyValuePair) {\n                FI.awaitFor(() => fiQuery(selector).length > 0)\n                    .then(() => {\n                        state.selector = selector;\n                        if (CSSKeyValuePair.property != null) state.value = fiQuery(CSSKeyValuePair.value)[CSSKeyValuePair.property]();\n                        else\n                            state.value = CSSKeyValuePair.value;\n                    });\n            },\n            observedManupilationArray: [],\n            trakcedManipulationStatesArray: [],\n            pushObservedManupilationArray: function (name, value, selector) {\n                if (fiUtils.getWebsiteMacro(selector) != null)\n                    fiUtils.fixed.observedManupilationArray.push(new fiUtils.fixed.ManipulationState(name, value, selector));\n            },\n            resetElementViewability: function (initManupilation) {\n                fiUtils.fixed.observedManupilationArray.forEach((element, index, arr) => {\n                    if (element.viewable && fiQuery(element.selector).length == 0) element.viewable = false;\n                });\n                for (var i = 0; i < fiUtils.fixed.trakcedManipulationStatesArray.length; i++) {\n                    if (!fiUtils.fixed.trakcedManipulationStatesArray[i].viewable) {\n                        fiUtils.fixed.trakcedManipulationStatesArray.splice(i, 1);\n                    }\n                }\n                if (fiUtils.fixed.trakcedManipulationStatesArray.length > 0) {\n                    fiUtils.fixed.manupilateThis(fiUtils.fixed.trakcedManipulationStatesArray, initManupilation);\n                }\n            },\n            isFixedState: function () {\n                return fiQuery('div.apd_docked').length > 0 || fiQuery('div#FIHeaderKickInner').length > 0 || fiQuery('div#FIBottomStickyInner').length > 0 || fiQuery('div.FIOnDemandWrapper > div.fi-docked').length > 0;\n            },\n            shouldWeManupiliate: function (arr, initManupilation) {\n                if (fiUtils.fixed.isFixedState()) {\n                    let changedObservedManupilationArray = arr.filter((element, index, array) => fiQuery(element.selector).length > 0 && !element.viewable ? element : '');\n                    if (changedObservedManupilationArray.length == 0 && fiUtils.fixed.trakcedManipulationStatesArray.length > 0) fiUtils.fixed.resetElementViewability(initManupilation);\n                    if (changedObservedManupilationArray.length > 0) {\n                        changedObservedManupilationArray.forEach((manupliationState) => fiUtils.fixed.trakcedManipulationStatesArray.push(manupliationState));\n                        for (var i = 0; i < changedObservedManupilationArray.length; i++) {\n                            for (var j = 0; j < fiUtils.fixed.observedManupilationArray.length; j++) {\n                                if (changedObservedManupilationArray[i].name == fiUtils.fixed.observedManupilationArray[j].name) {\n                                    fiUtils.fixed.observedManupilationArray[j].viewable = true;\n                                    FI.console.log(`${fiUtils.fixed.observedManupilationArray[j].name} is in view!`, ``, ``, `fiUtils.fixed`);\n                                    return true;\n                                }\n                            }\n                        }\n                    }\n                    return false;\n                }\n                return false;\n            },\n            manageManupiliations: function (arr, initManupilation) {\n                if (typeof initManupilation != \"function\") {\n                    FI.console.log(`ERROR: You provided an init manupilate but its not a function. This won't work`, ``, ``, `fiUtils.fixed`)\n                    return;\n                }\n                FI.awaitFor(() => fiUtils.fixed.shouldWeManupiliate(arr, initManupilation))\n                    .then(() => {\n                        fiUtils.fixed.manupilateThis(fiUtils.fixed.trakcedManipulationStatesArray, initManupilation);\n                        \/\/Re-init\n                        fiUtils.fixed.manageManupiliations(arr, initManupilation);\n                    });\n            },\n            manupilateThis(arr, initManupilation) {\n                fiUtils.fixed.placementsToManupiliate.forEach(($placement) => initManupilation(fiUtils.getManupiliationStateByHighestValuePerPlacementType(arr, $placement.type).value, $placement.type, fiUtils.getManupiliationStateByHighestValuePerPlacementType(arr, $placement.type).name));\n            }\n        },\n        getEnabledExtraOption: function ($placement, values, ...keysArr) {\n            let res = [];\n            if (Array.isArray(values) && typeof $placement.options.extra[values[j]] != \"undefined\" && typeof $placement.options.extra[values[j]][keysArr[i]] != \"undefined\") {\n                for (var i = 0; i < keysArr.length; i++) {\n                    for (var j = 0; j < values.length; j++) {\n                        res.push($placement.options.extra[values[j]][keysArr[i]]);\n                    }\n                }\n            }\n            if (res.length == keysArr.length) return res;\n\n            return null;\n        },\n        getOptions: function ($placement, ...options) {\n            return $placement.options[options];\n        },\n        getMoreEnabledExtraOptions: function (placementsArr, ...options) {\n            let placementsLength = 0;\n            options.forEach((option) => {\n                placementsLength += placementsArr.filter(($placement) => typeof $placement.options.extra[option] != \"undefined\" && $placement.options.extra[option].enabled).length\n            });\n            return placementsLength == options.length;\n        },\n        setPlacementOption: function ($placement, option, value) {\n            $placement.options[option] = value;\n        },\n        requireUtilFunctions: (module, ...functions) => functions.filter(func => typeof fiUtils[func] != 'function') > 0 ? fiUtils.console(`Your are missing some functions from the fiUtils in order to successfully use ${module} module`, `error`, module) : true,\n        getHBContainerIndex: (placementId) => FI.g_clientManager.placementQueue[placementId].creatives.findIndex(ele => ele.cid == -1),\n        getNoneHBCreativeIndexByCampaignId: (placementId, campaignId) => FI.g_clientManager.placementQueue[placementId].creatives.findIndex(creative => creative.cid == campaignId),\n        getHBCreativeInnerContainerIndexByCampainId: (placementId, campaignId) => FI.g_clientManager.placementQueue[placementId].creatives[fiUtils.getHBContainerIndex(placementId)].innerCreatives.findIndex(creative => creative.cid == campaignId),\n        getEventTypeFromEventObj: (e) => typeof e != \"undefined\" ? e.type : null,\n        removeBannerFromQueueByCampaignId: function (placementId, campaignId, isHB, e) {\n            if (fiUtils.getEventTypeFromEventObj(e) == 'SPCReturned') {\n                let noCreativeFoundLogMsg = `No matching creatives found for campaignId ${campaignId}! Maybe you forgot to set isHB? isHB value is ${isHB}`;\n\n                if (isHB && fiUtils.getHBContainerIndex(placementId) != -1) {\n                    FI.g_clientManager.placementQueue[placementId].creatives[fiUtils.getHBContainerIndex(placementId)].innerCreatives.splice(fiUtils.getHBCreativeInnerContainerIndexByCampainId(placementId, campaignId), 1);\n                    \/\/ if (FI.g_clientManager.placementQueue[placementId].creatives.length == 0)\n                    return;\n                } else if (fiUtils.getNoneHBCreativeIndexByCampaignId(placementId, campaignId) != -1) {\n                    FI.g_clientManager.placementQueue[placementId].creatives.splice(fiUtils.getNoneHBCreativeIndexByCampaignId(placementId, campaignId), 1);\n                    return;\n                }\n                fiUtils.console(noCreativeFoundLogMsg, `Warning`, `demandCapping`, placementId);\n                return;\n            } else\n                return fiUtils.console(`You either didn't specify the event or you called this method from another event which isn't SPCReturned. event found is ${typeof e != \"undefined\" ? e.type : e}`, `Error`, `demandCapping`, placementId);\n        },\n        removeCampaignFromQueueByCampaignId: (placementId, campaignId, isHB, e) => {\n            if (fiUtils.getEventTypeFromEventObj(e) == 'SPCReturned') {\n                let hbCreative = FI.g_clientManager.placementQueue[placementId].creatives[fiUtils.getHBContainerIndex(placementId)].innerCreatives[fiUtils.getHBCreativeInnerContainerIndexByCampainId(placementId, campaignId)];\n                if (isHB && typeof hbCreative != \"undefined\") return;\n                if ((isHB && hbCreative.cid != -1) || fiUtils.getNoneHBCreativeIndexByCampaignId(placementId, campaignId) != -1) {\n                    fiUtils.removeBannerFromQueueByCampaignId(placementId, campaignId, isHB, e);\n                    fiUtils.removeCampaignFromQueueByCampaignId(placementId, campaignId, isHB, e);\n                }\n                return;\n            } else\n                return fiUtils.console(`You either didn't specify the event or you called this method from another event which isn't SPCReturned. event found is ${typeof e != \"undefined\" ? e.type : e}`, `Error`, `demandCapping`, placementId);\n        },\n        getDaysDiff: (storageDate, currentDate) => {\n            if (storageDate != null && currentDate != null) {\n                var oneDay = 24 * 60 * 60 * 1000,\n                    firstDate = new Date(currentDate),\n                    secondDate = new Date(storageDate),\n                    diffDays = Math.round(Math.abs((firstDate - secondDate) \/ oneDay));\n\n                return diffDays;\n            }\n            return;\n        },\n        requiredExtraOptionProperties: (validationKeysArr, testedObject) => {\n            for (var key of validationKeysArr) {\n                if (!testedObject.hasOwnProperty(key)) return false;\n            }\n            return true;\n        },\n        isInstanceHadPassBackAfterSetVisible: ($instance, moduleName) => {\n            if (typeof FI.g_clientManager.trackingManager.history[$instance.instanceId].PassbackAfterSetVisible != \"undefined\") {\n                fiUtils.console(`PassbackAfterSetVisible received for placement ${$instance.placement.id} this will reset the counter!`, 'message', moduleName, $instance.placement.id);\n                return true;\n            }\n            return false;\n        },\n\t    batchedFor : (array, promiseLogic) => {\n\t        const sendBatch = (batchStart, batchEnd) => { \n\t            new Promise(resolve => {\n\t                for (var i = batchStart; i < batchEnd; i++) {\n\t                    promiseLogic(array, i, batchEnd);\n\t                }\n\t                resolve();\n\t            });\n\t        };\n\t        let length = array.length;\n\t        let batchEnd = 10;\n\t        for (let batchStart = 0, p = Promise.resolve(); batchStart < length; batchStart += 10) {\n\t            p = p.then(() => {\n\t                if (batchEnd + 10 > length) batchEnd = length;\n\t                sendBatch(batchStart, batchEnd);\n\t            })\n\t            .then(() => {\n\t                batchStart = batchEnd;\n\t            })\n\t            .then(() => {\n\t                batchEnd += 10;\n\t            });\n\t        }\n\t    },\n\t    typeExtention : {\n\t        inview: {\n\t            addInstance: ($placement, e) => {\n\t                $placement.stoppedSearch = false;\n\t                if (e.type == 'instanceSetVisibleComplete') $placement.options.placementLimitation++;\n\t                $placement.instances.forEach(instance => {\n\t                    if (! instance.demandFound && ! instance.hidden) instance.setStatus(\"tryLaterInit\");\n\t                });\n\t            }\n\t        }\n\t    },\n\t    getPropertyValueByModule: ($placement, moduleName, property, type, defaultValue = null, required = false) => {\n\t        if (typeof type == 'undefined') fiUtils.pageError('You are requesting a config without a type, this is not allowed', 'InContentAutoSelector');\n\t        const res = fiUtils.getExtra($placement)[moduleName][property];\n\t        if (typeof res == 'undefined' && required) fiUtils.pageError(`You've failed to provide the required config ${property}, the module will not run or lead to unexpected resutls`, 'InContentAutoSelector');\n\t        if (typeof res != 'undefined' && typeof res != type) fiUtils.pageError(`You've provided ${property} in the type ${typeof property} but it was expected to be ${type}`, 'InContentAutoSelector');\n\t        return typeof res != 'undefined' ? res : defaultValue; \n\t    },\n\t    getPlacementConfigByModule: ($placement, moduleName, propertiesObjects) => {\n\t        let config = {};\n\t        for (let propertiesObject of propertiesObjects) {\n\t            config[propertiesObject.prop] = fiUtils.getPropertyValueByModule($placement, moduleName, propertiesObject.prop, propertiesObject.type, propertiesObject.default, propertiesObject.required);\n\t        }\n\t        return config;\n\t    },\n\t    filterElementsInArr : (arr, condition) => {\n\t        return arr.filter((element) => {\n\t            return fiQuery(element.element).filter(condition).length > 0\n\t        })\n\t    },\n    };\n\n\tif (localStorage.apdAdmin == 1) {\n\t    Object.keys(fiUtils).forEach((utilFunc) => {\n\t        if (typeof fiUtils[utilFunc] == \"function\" && utilFunc.indexOf(\"error\") == -1 && FI.options.prependScript.indexOf(`${utilFunc}(`) == -1)\n\t            fiUtils.pageErrors.push({ \"message\": `The fiUtils function ${utilFunc} seems not to be in use in the website prepend`, \"module\": `fiUtils` });\n\t    });\n\t}\n});\n\nfiQuery(window).on('SPCReturned', function() {\n\tfiUtils.fixed[\"placementsToManupiliate\"] = fiUtils.getPlacementsPerCond({placement: \"enabledExtraOption\", is: \"stickyManipulation\"});\n    if (fiUtils.fixed.placementsToManupiliate.length > 0) {\n\t\tFI.state.stickyPlacements = $stickyPlacements = {\n\t\t\tpopulateManipulationStateArr: function() {\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"show\", {property: null, value: 0}, `header:not(.open)`);\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"navBarPush\", {property: \"height\", value: `header:not(.open)`}, `header:not(.open)`);\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"hide\", {property: null, value: -1000}, `header.open, div#modal-root > div.mask`);\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"cookieNoticePush\", {property: \"height\", value: `{{m:cookie_notice}}`}, `{{m:cookie_notice}}`);\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"bottomBarPush\", {property: \"outerHeight\", value: `{{m:bottom_on_scroll}}`}, `{{m:bottom_on_scroll}}`);\n\t\t\t\tfiUtils.fixed.pushObservedManupilationArray(\"close\", {property: null, value: 0}, `{{m:close_button}}`);\n\t\t\t}(),\n\t        manupilate: function(value, placementType, manupilateStateName) {\n\t        \tif (typeof placementType != \"undefined\" && typeof  fiUtils.fixed.manupiliateElementsPerPlacementType[placementType][manupilateStateName] != \"undefined\") fiUtils.fixed.manupiliateElementsPerPlacementType[placementType][manupilateStateName](value);\n\t        },\n\t        clearMechanisim : function () {\n\t        \tfiQuery(window).on('instanceSetVisibleComplete instanceHidden proceededToNextInSequence', function(e, $object, lastInSeq) { \n\t        \t\tlet $placement = typeof $object.placement != \"undefined\" ? $object.placement : $object;\n\t        \t\tif \t(typeof fiUtils.getExtra($placement).stickyManipulation != \"undefined\" && typeof fiUtils.fixed.manupiliateElementsPerPlacementType[$placement.type][\"close\"] != \"undefined\") {\n\t        \t\t\tif (e.type == \"instanceSetVisibleComplete\") {\n\t\t\t\t\t\t   \tfiQuery('div#FIHeaderKickCloseButton').on('click', function(){\n\t\t\t\t\t\t        fiQuery(fiUtils.getWebsiteMacro(`header:not(.open)`)).css({transform: ``});\n\t\t\t\t\t\t    });\n\t\t\t\t\t\t} else {\n\t\t\t        \t\tfiQuery(fiUtils.getWebsiteMacro(`header:not(.open)`)).css({transform: ``});\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t        }()\n\t\t};\n\t\t\/\/init\n\t\tfiUtils.fixed.manageManupiliations(fiUtils.fixed.observedManupilationArray ,$stickyPlacements.manupilate);\n\t\t\n\t}\n});\n\n\/\/Version 2.0.0\nfiQuery(window).on('SPCReturned', function() {\n    FI.state.backfillRefreshObserver = $backfillRefreshObserver = {\n      targetPlacements : fiUtils.getPlacementsPerCond({placement: \"enabledExtraOption\", is: \"backfill\"})\n    }\n\n    if ($backfillRefreshObserver.targetPlacements.length > 0) {\n        Object.assign($backfillRefreshObserver, {\n            initObserver : function($placement) {\n                if (typeof fiUtils.getExtra($placement).backfill != \"undefined\" && typeof fiUtils.getExtra($placement).backfill.selectors != \"undefined\" && typeof fiUtils.getExtra($placement).backfill.selectors.adRenderAfterAdCall != \"undefined\") {\n                    FI.awaitFor(() => fiQuery(typeof fiUtils.getExtra($placement) != \"undefined\" ?  fiUtils.getExtra($placement).backfill.selectors.adRenderAfterAdCall : fiUtils.getExtra($placement).backfill.selectors.adRenderAfterAdCall).length > 0)\n                        .then(() => {\n                            $placement.hide();\n                            FI.console.log(`Placement #${$placement.id} has been hidden has it's backfill refresh selector returned true`, $placement.id, ``, `backfillRefreshObserver`);\n                        });\n                    FI.console.log(`Set up a new refresh observer for placement #${$placement.id} tracking adRenderAfterAdCall selector (see b)`, $placement.id, typeof fiUtils.getExtra($placement) != \"undefined\" ?  fiUtils.getExtra($placement).backfill.selectors.adRenderAfterAdCall : fiUtils.getExtra($placement).backfill.selectors.adRenderAfterAdCall,  `backfillRefreshObserver`);\n                } else\n                    fi.fiUtils.pageError(`Placement backfill `, `backfillRefreshObserver`);\n            },\n        });\n        fiQuery.each($backfillRefreshObserver.targetPlacements, function(i, $placement) {\n            fiQuery(window).on('instanceSetVisibleComplete', function(e, $instance) {\n                if ($placement.id == $instance.placement.id && typeof $instance.placement.refreshObserver == 'undefined')\n                    $backfillRefreshObserver.initObserver($instance.placement);\n            });\n        });\n    }\n});\n\nfiQuery(window).on('SPCReturned', function() {\n    FI.state.slowSelectorsPlacementsArray = $FIslowSelectors = {\n        targetPlacements : fiUtils.getPlacementsPerCond({placement: \"enabledExtraOption\", is: \"slowSelector\"}),\n        slowSelectors : {}\n    }\n    Object.assign($FIslowSelectors, {\n        slowSelectorInterval: 3000,\n        slowSelectorTimeout: null,\n        findAllElements: function (slowSelectorPlacementId, slowSelectorPlacement, container) {\n            if (typeof fiUtils.getExtra(slowSelectorPlacement).slowSelector.selector != 'undefined') {\n                if (typeof fiUtils.getExtra(slowSelectorPlacement).slowSelector.markerClass != 'undefined') { \n                    let pipeSelectors = fiUtils.getExtra(slowSelectorPlacement).slowSelector.selector.split('|'),\n                        filter = typeof fiUtils.getExtra(slowSelectorPlacement).slowSelector.filter != 'undefined' ? fiUtils.getExtra(slowSelectorPlacement).slowSelector.filter : '*',\n                        elementsToMark;\n                        for (var i = 0; i < pipeSelectors.length; i++) {\n                            elementsToMark = fiQuery(pipeSelectors[i]).filter(filter);\n                            if (elementsToMark.length) break;\n                        }\n                        return elementsToMark;\n                } else {\n                    fiUtils.pageError(`You've specified a slow scroll selector but no marker class, placement ${slowSelectorPlacementId} will probably never render`, `slowSelector`);\n                }\n            } else {\n                fiUtils.pageError(`You didn't specify a slow scroll selector, placement ${slowSelectorPlacementId} will never render`, `slowSelector`);\n            }\n        },\n        markAllElements : function (slowSelectorPlacementId, slowSelectorPlacement, container) {\n            $FIslowSelectors.findAllElements(slowSelectorPlacementId, slowSelectorPlacement, container).addClass(fiUtils.getExtra(slowSelectorPlacement).slowSelector.markerClass);\n        }\n    });\n\n    \/\/init\n    if (fiUtils.getWebsiteMacro('section.article-content') != null) {      \n        fiQuery.each($FIslowSelectors.targetPlacements, function(slowSelectorPlacementId, slowSelectorPlacement) {\n            $FIslowSelectors.slowSelectorInterval = typeof fiUtils.getExtra(slowSelectorPlacement).slowSelector.customIntervalTimeout != \"undefined\" ? fiUtils.getExtra(slowSelectorPlacement).slowSelector.customIntervalTimeout : 3000;\n            $FIslowSelectors.slowSelectorTimeout = typeof fiUtils.getExtra(slowSelectorPlacement).slowSelector.maxSelectorCycles != \"undefined\" ? fiUtils.getExtra(slowSelectorPlacement).slowSelector.maxSelectorCycles : null;\n            FI.awaitFor(() => $FIslowSelectors.findAllElements(slowSelectorPlacementId, slowSelectorPlacement).length > 0, $FIslowSelectors.slowSelectorInterval, $FIslowSelectors.slowSelectorTimeout)\n               .then(() => $FIslowSelectors.markAllElements(slowSelectorPlacementId, slowSelectorPlacement));\n        });\n        fiQuery(window).on('instanceSetVisibleComplete instanceHidden', function(e, $instance) { \n            if (fiUtils.isLastInstance($instance) && fiUtils.isPlacementOptionEnabled($instance, \"slowSelector\") && fiUtils.isPlacementOptionEnabled($instance, \"infinityScroll\")) {\n                $instance.$element.parents('section.article-content').addClass(`fi-resolved_${$instance.placement.id}`);\n                FI.awaitFor(() => fiQuery(`section.article-content:not(.fi-resolved_${$instance.placement.id})`).length > 0, $FIslowSelectors.slowSelectorInterval, $FIslowSelectors.slowSelectorTimeout)\n                    .then(() => $FIslowSelectors.markAllElements($instance.placement.id, $instance.placement ,`section.article-content:not(.fi-resolved_${$instance.placement.id})`));\n            }\n        });\n    } else\n        fiUtils.pageError(`section.article-content is not defined! Please define it in the websites macros tabs`, `slowSelector`);\n});\nfiQuery(window).on('SPCReturned', function () {\n    let moduleName = 'InContentAutoSelector';\n    FI.state.InContentAutoSelector = $InContentAutoSelector = {\n        InContentAutoSelectorPlacementsArray: fiUtils.getPlacementsPerCond({ placement: \"enabledExtraOption\", is: \"InContentAutoSelector\" })\n    }\n    Object.assign($InContentAutoSelector, {\n        getAutoInContentChain : function() {\n            $InContentAutoSelector.autoInContentChain = $InContentAutoSelector.InContentAutoSelectorPlacementsArray.sort(($placementA, $placementB) => {\n                if (fiUtils.getExtra($placementA).InContentAutoSelector.instanceSequence == fiUtils.getExtra($placementB).InContentAutoSelector.instanceSequence && ! fiUtils.getExtra($placementA).InContentAutoSelector.parallel) {\n                    fiUtils.pageError(`There are two instance positions with the same value the placements are ${$placementA} and ${$placementB}. This will have unexpected resutls`, `InContentAutoSelector`);\n                    return;\n                }\n                return fiUtils.getExtra($placementA).InContentAutoSelector.instanceSequence - fiUtils.getExtra($placementB).InContentAutoSelector.instanceSequence;\n            });\n            fiUtils.console(`The following placements are allocated as auto incontent and will render in the following order ${$InContentAutoSelector.autoInContentChain.map((e) => e.id)}`, `message`, `InContentAutoSelector`); \n        }(),\n        parallelContainer : `<div class=\"fi-parallel\" style=\"display: flex; margin-bottom: 15px;\"><div class=\"fi-aic-pmi\"><\/div><\/div>`\n    });\n\n    if (fiUtils.getWebsiteMacro(`{{m:feed}}`) == null) fiUtils.console(`The website feed macro is undefined`, `InContentAutoSelector`);\n    if (fiUtils.getWebsiteMacro(`section.article-content`) == null) fiUtils.console(`The website article macro is undefined`, `InContentAutoSelector`);\n    if ($InContentAutoSelector.InContentAutoSelectorPlacementsArray.length == 0) fiUtils.console(`There are no auto in-content placements on this page but the in-content module is set, is this weird?`, `message`, `InContentAutoSelector`);\n    else {\n        Object.assign($InContentAutoSelector, fiUtils.getPlacementConfigByModule($InContentAutoSelector.autoInContentChain[0], moduleName, [\n            {prop: \"customDistanceBetweenInstances\", type: 'number',default:  null},\n            {prop: \"precentageViewPortDistance\", type: 'number',default:  null},\n            {prop: \"distanceFromOtherAds\", type: 'boolean',default:  true},\n            {prop: \"distanceFromMedia\", type: 'boolean',default:  true}\n        ]));\n\n        if (fiUtils.getAllErrors('InContentAutoSelector').length == 0) {\n            Object.assign($InContentAutoSelector, {\n                takeDistanceFromMedia: function () {\n                    let filter = \"*\";\n                    if ($InContentAutoSelector.distanceFromMedia) {\n                        filter = `:distanceFromElement(:not(:not(section.article-content)) :not(:not(img,figure,blockquote,form,video,div.related-news,:has(img,figure,blockquote,form,video))),200,false)`;\n                    }\n                    return filter;\n                },\n                takeDistanceFromOtherAds: function () {\n                    let filter = \"*\";\n                    if ($InContentAutoSelector.distanceFromOtherAds) {\n                        filter = `:distanceFromElement(:not(:not(section.article-content)) iframe:not([src*=outbrain]):not([src*=pinterest]):not([src*=youtube]):not([src*=instagram]):not([src*=twitter]):height(>1),${FI.state.deviceDetected == \"smartphone\" ? screen.availHeight : 400},false):distanceFromElement(:not(:not(section.article-content)) div[id*=arcad],300,false):distanceFromElement(:not(:not(section.article-content)) div.nd-dfp-wrapper,300,false):distanceFromElement(:not(:not(section.article-content)) blockquote,10,false)`;\n                    }\n                    return filter;\n                },\n                getAllOpprotunites: function () {\n                    let titlesSelector = \":prevIs(:not(:header,:hasOnly(strong,bold,b),strong,bold,b,.ob-widget-header,table))\",\n                        badElements = \":not(:has(table,li,p)):not(thumbcaption,[class^=ob], a, noscript, script, style, figcaption, .jnews_content_inline_ads)\",\n                        goodElements = \"div.block-margin-bottom, div.mobile-listing, div.search-results, div.may-interest-you\",\n                        inBetweenTextNodesElements = \":prevTextNodeWordCount(5), :nextTextNodeWordCount(5)\",\n                        feedMacro = fiUtils.getWebsiteMacro(`{{m:feed}}`) == null ? null : `{{m:feed}}`,\n                        articleMacro = `section.article-content`,\n                        elements;\n                    if (feedMacro != null && fiQuery(`${feedMacro}`).length > 0) \n                        elements = fiQuery(`${feedMacro}`).children();\n                    else {\n                        elements = fiQuery(`${articleMacro}`)\n                            .find(\"*\")\n                            .filter(`:hasDirectTextNode(), ${inBetweenTextNodesElements}, :block`)  \n                            .filter(badElements)\n                            .filter(titlesSelector)\n                            .filter($InContentAutoSelector.takeDistanceFromMedia())\n                            .filter($InContentAutoSelector.takeDistanceFromOtherAds());\n                        if (fiQuery(elements).last().filter(`:nextIs(*)`).length == 0) elements = elements.add(fiQuery(elements).last());\n                        if (! $InContentAutoSelector.takeDistanceFromMedia()) goodElements += \",img,figure,blockquote,form\";\n                        elements = elements.add(fiQuery(goodElements));\n                    }\n                    return elements;\n                },\n                potentialElementsArr: [],\n                potentialElements: function (container) {\n                    let potentialElementsSelector = typeof container == 'undefined' ? $InContentAutoSelector.getAllOpprotunites() : fiQuery(container).find($InContentAutoSelector.getAllOpprotunites());\n                    let elementsObject = {};\n                    let length = potentialElementsSelector.length;\n                    fiUtils.batchedFor(potentialElementsSelector, function(arr, i) {\n                        elementsObject = { \"element\": fiQuery(arr[i]), \"offsetTop\": arr[i].getBoundingClientRect().top }; \n                        $InContentAutoSelector.potentialElementsArr.push(elementsObject);\n                        if (i == arr.length) return $InContentAutoSelector.potentialElementsArr;\n                    });  \n                },\n                distanceBetweenInstances: function () {\n                    if ($InContentAutoSelector.customDistanceBetweenInstances == null\n                        && $InContentAutoSelector.precentageViewPortDistance == null)\n                        return FI.state.deviceDetected == \"smartphone\" ? screen.availHeight : 450;\n                    if ($InContentAutoSelector.customDistanceBetweenInstances != null\n                        && $InContentAutoSelector.precentageViewPortDistance != null) {\n                        fiUtils.pageError(`You've provided BOTH customDistanceBetweenInstances AND precentageViewPortDistance. This is not allwed, no placement will render, please remove one of them`, `InContentAutoSelector`);\n                        return -1;\n                    }\n                    return $InContentAutoSelector.customDistanceBetweenInstances != null ? $InContentAutoSelector.customDistanceBetweenInstances : FI.state.deviceDetected == \"smartphone\" ? screen.availHeight * $InContentAutoSelector.precentageViewPortDistance : 450 * $InContentAutoSelector.precentageViewPortDistance;\n                }(),\n                markElementForNextPlacement: function () { \n                    fiQuery(window).on('instanceHidden instanceSetVisibleComplete', function (e, $instance) {\n                        if (fiUtils.getPlacementsPerCond({ placement: \"enabledExtraOption\", is: \"InContentAutoSelector\" }).filter(placement => placement.id == $instance.placement.id).length > 0) {\n                            if ($instance.placement.type == \"inview\") fiUtils.typeExtention['inview'].addInstance($instance.placement, e);\n                            if (e.type == \"instanceHidden\") { \n                                const nextPlacement = $InContentAutoSelector.getNextPlacementToMarkElementsFor($instance.placement);\n                                $instance.$element.addClass(`fi-aic_${nextPlacement.id}`);          \n                                if ($instance.placement.height != nextPlacement.height) $InContentAutoSelector.markOnePerMinDistanceElements(nextPlacement);\n                            }\n                        }\n                    });\n                }(),\n                getNextPlacementToMarkElementsFor : function ($instancePlacement) {\n                    if (typeof fiUtils.getExtra($instancePlacement).InContentAutoSelector.instanceSequence == 'undefined') return $InContentAutoSelector.autoInContentChain[1];\n                    if ($InContentAutoSelector.autoInContentChain[fiUtils.getExtra($instancePlacement).InContentAutoSelector.instanceSequence + 1] > $InContentAutoSelector.autoInContentChain.length) return null;\n                    else return $InContentAutoSelector.autoInContentChain[fiUtils.getExtra($instancePlacement).InContentAutoSelector.instanceSequence + 1];\n                },\n                offsetTopAccumilated : 0,\n                getPlacementOffsetAdjustment: ($placement) => $placement.height + (typeof $placement.options.morestylesJSON[\"margin-top\"] != \"undefined\" ? parseInt($placement.options.morestylesJSON[\"margin-top\"]) : 0),\n                markOnePerMinDistanceElements: function ($placement = $InContentAutoSelector.autoInContentChain[0]) {\n                    let currentPotentialElements = fiUtils.filterElementsInArr($InContentAutoSelector.potentialElementsArr, `:distanceFromElement([class*=fi-aic], ${$InContentAutoSelector.distanceBetweenInstances},false)`),\n                        placementOffsetAdjustment = $InContentAutoSelector.getPlacementOffsetAdjustment($placement),\n                        markingClass = `fi-aic_${$placement.height}`; \n                    if (currentPotentialElements.length == 0) {\n                        fiUtils.console(`No potential elements identified on this page`, `message`, `InContentAutoSelector`);\n                        return;\n                    }\n                    if ($InContentAutoSelector.distanceBetweenInstances == -1) {\n                        return;\n                    }\n                    if (fiUtils.getExtra($InContentAutoSelector.autoInContentChain[0]).InContentAutoSelector.parallel) {\n                        $InContentAutoSelector.appendParallelContainer(currentPotentialElements[0]);\n                        fiQuery(`.fi-parallel:not(${markingClass})`).addClass(markingClass);\n                    } else\n                        currentPotentialElements[0].element.addClass(markingClass);\n                    $InContentAutoSelector.offsetTopAccumilated = currentPotentialElements[0].offsetTop;\n                    let length = currentPotentialElements.length;\n                    fiUtils.batchedFor(currentPotentialElements, function(arr, i) {\n                        if (typeof arr[i + 1] != \"undefined\") {\n                            if (arr[i + 1].offsetTop + placementOffsetAdjustment > $InContentAutoSelector.offsetTopAccumilated + $InContentAutoSelector.distanceBetweenInstances ) {\n                                if (fiUtils.getExtra($InContentAutoSelector.autoInContentChain[0]).InContentAutoSelector.parallel) {\n                                    $InContentAutoSelector.appendParallelContainer(arr[i + 1]);\n                                    fiQuery(`.fi-parallel:not(${markingClass})`).addClass(markingClass);\n                                } else\n                                    arr[i + 1].element.addClass(markingClass);\n                                $InContentAutoSelector.offsetTopAccumilated = arr[i + 1].offsetTop;\n                            }\n                        }\n                    });\n                },\n                appendParallelContainer : function(element) { \n                    fiQuery(element.element).after($InContentAutoSelector.parallelContainer);\n                },\n                init: function () {\n                    FI.awaitFor(() => $InContentAutoSelector.potentialElementsArr.length > 0)\n                        .then(() => {\n                                $InContentAutoSelector.markOnePerMinDistanceElements();\n                                (function loop(time = 0) {\n                                    if (time < 10) {\n                                      setTimeout(function () {\n                                        $InContentAutoSelector.markOnePerMinDistanceElements();\n                                        time++;\n                                        loop(time)\n                                      }, 1000);  \n                                    }\n                                }());\n                            });\n                },\n                infinityScroll: false,\n            });\n            Promise.resolve()\n                .then(() => $InContentAutoSelector.potentialElements())\n                .then(() => $InContentAutoSelector.init());\n\n            fiQuery(window).on('instanceSetVisibleComplete instaneHidden', function (e, $instance) {\n                if (fiUtils.getPlacementsPerCond({ placement: \"enabledExtraOption\", is: \"InContentAutoSelector\" }, \n                                                { placement: \"enabledExtraOption\", is: \"infinityScroll\" }).length > 0\n                                                && typeof fiUtils.getPlacementsPerCond({ placement: \"enabledExtraOption\", is: \"InContentAutoSelector\" }).find(ele => $instance.placement.id == ele.id) != \"undefined\"\n                                                && fiUtils.isLastInstance($instance)\n                                                && ! $InContentAutoSelector.infinityScroll) {\n                    $InContentAutoSelector.infinityScroll = true;\n                    $instance.$element.parents(`section.article-content`).addClass(`fi-auto`);\n                    let curentElementsLength = $InContentAutoSelector.potentialElementsArr.length;\n                    $InContentAutoSelector.potentialElementsArr = [];\n                    FI.awaitFor(() => fiQuery(`:not(:not(section.article-content)):not(.fi-auto)`).length > 0)\n                        .then(() => $InContentAutoSelector.potentialElements(`:not(:not(section.article-content)):not(.fi-auto)`))\n                        .then(() => $InContentAutoSelector.init());\n                }\n            });\n        }\n    }\n});\nfiQuery(window).on('SPCReturned', function() {\nFI.state.websitePrependInContent = $websitePrependInContent = {\nmultiInstancePlacementArray : fiUtils.getPlacementsPerCond({placement: \"enabledExtraOption\", is: \"websitePrependInContent\"})\n}\n\nif ($websitePrependInContent.multiInstancePlacementArray.length != 1 || \"section.article-content\".indexOf('{') != -1 || fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).websitePrependInContent.potentialElementsSelector.indexOf('section.article-content') == -1) {\nfiUtils.pageError(`Placement count marked as WebsitePrependInContent configuration is less or more than 1, this is not allowed, please make sure a single placement is returned OR the website article macro is undefined`, `websitePrependInContent`);\n} else {\n$websitePrependInContent.multiInstancePlacement = $websitePrependInContent.multiInstancePlacementArray[0];\nObject.assign($websitePrependInContent, {\ndistanceBetweenInstances : function() {\nlet MIPOptions = fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).websitePrependInContent;\nif (typeof MIPOptions.customDistanceBetweenInstances == 'undefined' && typeof MIPOptions.precetageViewPortDistance == 'undefined')\nreturn {viewport_height};\nif (typeof MIPOptions.customDistanceBetweenInstances != 'undefined' && typeof MIPOptions.precetageViewPortDistance != 'undefined') {\nfiUtils.pageError(`You've provided BOTH customDistanceBetweenInstances AND precetageViewPortDistance. This is not allwed, no placement will render, please remove one of them`, `websitePrependInContent`);\nreturn -1;\n}\nif (typeof MIPOptions.customDistanceBetweenInstances != 'undefined') return MIPOptions.customDistanceBetweenInstances;\nif (MIPOptions.precetageViewPortDistance <= 1 && MIPOptions.precetageViewPortDistance > 0) return {viewport_height} * MIPOptions.precetageViewPortDistance;\nfiUtils.pageError(`You've provided precetageViewPortDistance which is not between 0 and 1, this cannot be calculated`,`websitePrependInContent`);\nreturn -1;\n}(),\npotentialElements : function(container) {\nlet MIPOptions = fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).websitePrependInContent,\npotentialElementsSelector = typeof container == 'undefined' ? MIPOptions.potentialElementsSelector : MIPOptions.potentialElementsSelector.replace(\/section.article-content\/g, container),\npotentialElements = typeof MIPOptions.filter == 'undefined' ? fiQuery(potentialElementsSelector) : fiQuery(potentialElementsSelector).filter(MIPOptions.filter);\nreturn fiQuery.map(potentialElements, function(elm,i) {\nreturn { \"element\": fiQuery(elm), \"offsetTop\" : elm.getBoundingClientRect().top + fiQuery(window).scrollTop() };\n});\n},\nmarkOnePerMinDistanceElements : function(container) {\nlet MIPOptions = fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).websitePrependInContent;\nvar currentPotentialElements = $websitePrependInContent.potentialElements(container);\nif (currentPotentialElements.length == 0) {\nfiUtils.pageError(`No potential elements identified on this page`, `websitePrependInContent`);\nreturn;\n}\nif ($websitePrependInContent.distanceBetweenInstances == -1) {\nfiUtils.pageError(`The module failed in setting the requested distanceBetweenInstances, check your configuration`, `websitePrependInContent`);\nreturn;\n}\n\ncurrentPotentialElements[0].element.addClass(`_${$websitePrependInContent.multiInstancePlacement.id}`);\nvar offsetTopAccumilated = currentPotentialElements[0].offsetTop;\nfor (var i = 1; i < currentPotentialElements.length; i++) {\nif (typeof MIPOptions.maxIterations != \"undefined\" && fiQuery(`section.article-content:not(.fi-multi-instance_${$websitePrependInContent.multiInstancePlacement.id}) ._${$websitePrependInContent.multiInstancePlacement.id}`).length == MIPOptions.maxIterations) break;\nif (currentPotentialElements[i].offsetTop + $websitePrependInContent.multiInstancePlacement.height > offsetTopAccumilated + $websitePrependInContent.distanceBetweenInstances) {\ncurrentPotentialElements[i].element.addClass(`_${$websitePrependInContent.multiInstancePlacement.id}`);\noffsetTopAccumilated = currentPotentialElements[i].offsetTop;\n}\n}\n}\n});\nFI.awaitFor(() => $websitePrependInContent.potentialElements().length > 0).then(() => $websitePrependInContent.markOnePerMinDistanceElements());\nFI.state.isLastInstance = ($instance) => $instance.instanceId.split('_')[2] == $instance.placement.instances.length - 1;\nif (typeof fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).infinityScroll != \"undefined\" && fiUtils.getExtra($websitePrependInContent.multiInstancePlacementArray[0]).infinityScroll.enabled == true) {\nfiQuery(window).on('instanceSetVisibleComplete', function(e, $instance) {\nif ($websitePrependInContent.multiInstancePlacement.id == $instance.placement.id\n&& FI.state.isLastInstance($instance)) {\n$instance.$element.parents('section.article-content').addClass(`fi-multi-instance_${$instance.placement.id}`);\nFI.awaitFor(() => $websitePrependInContent.potentialElements(`section.article-content:not(.fi-multi-instance_${$instance.placement.id})`).length > 0).then(() => $websitePrependInContent.markOnePerMinDistanceElements(`section.article-content:not(.fi-multi-instance_${$instance.placement.id})`));\n}\n});\n}\n}\n});"},"sessionTracking":true,"GDPRApplies":false,"USnatApplies":true,"USstatesApplies":false,"cmp_enforce":null,"incognito":null,"placements":[],"messages":[{"type":"info","text":"Will serve you ALL LIVE placements (all enabled placements, that are not in QA and not hidden)"}],"utm":{"utm_source":"direct","utm_medium":"direct","utm_campaign":"","utm_content":"","utm_keyword":"","utm_ref":""}}