/** * Function: blmGetIcon * Get the requested icon graphic */ function blmGetIcon( type, id ) { //Initialize icons var icons = { geotag: '', angle_down: '', times: '', file: '', location_arrow: '', search: '', spinner: '', bloom: '' }; //Ignore if invalid icon request if (!icons[type] ) { return null; } return icons[type]; }//blmGetIcon ; !function(e){var n={};function t(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,t),r.l=!0,r.exports}t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var r in e)t.d(o,r,function(n){return e[n]}.bind(null,r));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=0)}([function(e,n,t){"use strict";t.r(n);var o=()=>{window.engageLibrary=window.engageLibrary||{};const e=window.location;function n(e){const n=blueConicClient.getSegments(),t=[];if(n.length>0)for(let e=0;e"free"===e.Paywall_Level||"premium"===e.Paywall_Level||"article"!==e["Page Type"]&&"UA-61435456-39"===e.ga_ua);if(e)return console.log("archive check: stop checking because of: ",e),!1}console.log("archive check: business check good, now check date");const n=e.href.split("/"),t=`${n[4]}/${n[5]}/${n[3]}`;console.log(t);const o=new Date,r=new Date(t),a=new Date(r.setDate(r.getDate()+90));return console.log(a),console.log(o),{today:o,expireDate:a}}function o(e,n){return e>n||(console.log("archive check: has not been 90 days yet"),!1)}function r(e){let n=window.location.hostname;return n=n.replace("www.","").replace("preprod.","").replace("develop.",""),!(-1===e.indexOf(n))}function a(e,n){return{url:`${window.authentication_config.entitlementsEndpoint}newsletters`,data:JSON.stringify({email:e,preferenceId:n,domain:function(e=!1){const{hostname:n}=window.location;let t=n;e&&"string"==typeof e&&(t=e);const o=t.split(".");return`${o[o.length-2]}.${o[o.length-1]}`}()}),method:"POST",timeout:0,headers:{"X-Api-Key":window.authentication_config.entitlementsAPIKey}}}function i(e,n,t,o,r,i,c){e.preventDefault();var d=function(e){var n=new RegExp(/^(([^<>()\[\]\\.,;:\s@']+(\.[^<>()\[\]\\.,;:\s@']+)*)|('.+'))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/i);return e?n.test(e)?(jQuery("#registration__form .submit").text("submitting..."),{valid:!0,message:""}):{valid:!1,message:"Please, enter a valid email."}:{valid:!1,message:"Please, enter an email."}}(n.val());if(s(d,t,n),d.valid&&o.length>0){let e=JSON.parse(decodeURIComponent(o)),l=e;Array.isArray(l)&&(l=e[0].id.split(","));const d=a(n.val(),l);$.ajax(d).done(function(e){r.hide(),i.html(c),i.show(),s({valid:!0},t,n),n.val(""),localStorage.setItem("regwallSuccess","yes"),setTimeout(function(){Connext.Run()},350)}).fail(function(e){let o={Message:"Sorry, we could not sign you up to the newsletter."};e||(o={Message:"Error! Empty result or no connection"}),function(e){s({valid:!1,message:e.ErrorMessage||e.Message},t,n)}(o)})}else 0===o.length&&l("Newsletter field is empty",t,!0)}function l(e,n,t){t?(n.html(e),n.show()):(n.text(""),n.hide())}function s(e,n,t){e.valid?(l("",n,!1),t.removeClass("connext-validation-error")):(l(e.message,n,!0),t.addClass("connext-validation-error"))}function c(e){let n;switch(e){case 1:n="A";break;case 2:n="B";break;case 3:n="C";break;case 4:n="D";break;case 5:n="E";break;default:n="empty"}return n}function d(){return window.sophiWallConfig&&!window.sophiWallConfig.error?window.sophiWallConfig:{}}function g(){return!(!window.sophiWallConfig||window.sophiWallConfig.error)&&window.sophiWallConfig.wall}window.engageLibrary.panymaGiveBCAccess=(()=>n("PANYMA All Subs + Recents")),window.engageLibrary.caGiveBCAccess=(()=>n("CA Print Only Subs")),window.engageLibrary.pmpGiveBCAccess=(()=>n("PMP_KnownNonSubsAll")),window.engageLibrary.crossOverGiveBCAccess=(()=>n("CrossOver PremSubs")),window.engageLibrary.bcAdblockDetection=(()=>n("Adblock Users")),window.engageLibrary.isEntitledValue=(()=>{const e=window.localStorage.getItem("__MNG_Session");return JSON.parse(e).isEntitled}),window.engageLibrary.printCheck=(()=>{const e=Connext.Storage.GetUserData().DigitalAccess.Subscription.HouseHoldSubscriptionLevel;return!!["5","16","23","25","35","36","43","45","55","65","75","85","95","105","115","145"].find(n=>n===e)}),window.engageLibrary.getPageType=(()=>{if(void 0!==window.dataLayer){const e=window.dataLayer.find(e=>e["Page Type"]);return!!e&&e["Page Type"]}return!1}),window.engageLibrary.getSection=(()=>{if("undefined"!=typeof dataLayer){const e=window.dataLayer.find(e=>e.Section);return!!e&&e.Section}return!1}),window.engageLibrary.getPaywallLevel=(()=>{if("undefined"!=typeof dataLayer){const e=window.dataLayer.find(e=>e.Paywall_Level);return!!e&&e.Paywall_Level}return!1}),window.engageLibrary.testingLocalStorage=(()=>{const e=localStorage.getItem("abLocal");if(e)window.dataLayer.push({event:"abLocal_event",abLocal:e});else{const e=c(Math.floor(Math.random()*Math.floor(2))+1);localStorage.setItem("abLocal",e),window.dataLayer.push({event:"abLocal_event",abLocal:e})}const n=localStorage.getItem("abcLocal");if(n)window.dataLayer.push({event:"abcLocal_event",abcLocal:n});else{const e=c(Math.floor(Math.random()*Math.floor(3))+1);localStorage.setItem("abcLocal",e),window.dataLayer.push({event:"abcLocal_event",abcLocal:e})}if(!localStorage.getItem("abcdLocal")){const e=c(Math.floor(Math.random()*Math.floor(4))+1);localStorage.setItem("abcdLocal",e)}if(!localStorage.getItem("abcdeLocal")){const e=c(Math.floor(Math.random()*Math.floor(5))+1);localStorage.setItem("abcdeLocal",e)}}),window.engageLibrary.testingSessionStorage=(()=>{if(!window.sessionStorage.getItem("abSession")){const e=c(Math.floor(Math.random()*Math.floor(2))+1);window.sessionStorage.setItem("abSession",e)}if(!window.sessionStorage.getItem("abcSession")){const e=c(Math.floor(Math.random()*Math.floor(3))+1);window.sessionStorage.setItem("abcSession",e)}if(!window.sessionStorage.getItem("abcdSession")){const e=c(Math.floor(Math.random()*Math.floor(4))+1);window.sessionStorage.setItem("abcdSession",e)}if(!window.sessionStorage.getItem("abcdeSession")){const e=c(Math.floor(Math.random()*Math.floor(5))+1);window.sessionStorage.setItem("abcdeSession",e)}}),window.engageLibrary.premiumFeatureExclusiveDP=(()=>window.location.hostname.includes("denverpost")&&document.getElementById("main").querySelector("article").className.includes("feature-exclusive")),window.engageLibrary.scrollDepth=(()=>{const e=[];window.onscroll=function(e,n){let t,o,r,a=null,i=0;const l=()=>{i=new Date,a=null,r=e.apply(t,o)};return()=>{const s=new Date;i||(i=s);const c=n-(s-i);return t=this,o=arguments,c<=0?(clearTimeout(a),a=null,i=s,r=e.apply(t,o)):a||(a=setTimeout(l,c)),r}}(()=>{const{body:n}=document,t=document.documentElement,o=Math.max(n.scrollHeight,n.offsetHeight,t.clientHeight,t.scrollHeight,t.offsetHeight),r=window.innerHeight||t.clientHeight,a=n.scrollTop||t.scrollTop,i=function(e){return{15:parseInt(.15*e,10),25:parseInt(.25*e,10),50:parseInt(.5*e,10),75:parseInt(.75*e,10),100:e-5}}(o),l=a+r;e.length>=4||function(n,t){!function(e,n){let t;for(t in e)if(e.hasOwnProperty(t)&&!1===n.call(e[t],t,e[t]))break}(n,(n,o)=>{if(-1===function(e,n){let t,o;for(t=0,o=n.length;t=o){let t="0";switch(n){case"15":t="Scroll15";break;case"25":t="Scroll25";break;case"50":t="Scroll50";break;case"75":t="Scroll75";break;case"100":t="Scroll100"}const o=new Event(t);document.dispatchEvent(o),e.push(n)}})}(i,l)},500)}),window.engageLibrary.bcLowaCheck=(()=>{let t=e.hostname;t=t.replace("www.","").replace("preprod.","").replace("develop.","");let o="";return-1!==["twincities.com","thereporteronline.com","delcotimes.com","timesherald.com","pottsmerc.com","trentonian.com","dailylocal.com","readingeagle.com","themorningsun.com","theoaklandpress.com","dailytribune.com","macombdaily.com","morningjournal.com","news-herald.com","dailyfreeman.com","oneidadispatch.com","saratogian.com","troyrecord.com","bostonherald.com","lowellsun.com","sentinelandenterprise.com","times-standard.com","montereyherald.com","chicoer.com","orovillemr.com","redbluffdailynews.com","paradisepost.com","thereporter.com","timesheraldonline.com","dailydemocrat.com","record-bee.com","ukiahdailyjournal.com","pressandguide.com","thenewsherald.com"].indexOf(t)?n(o="MNG Subs"):-1!==["dailycamera.com","denverpost.com","timescall.com","reporterherald.com","greeleytribune.com","eptrail.com","canoncitydailyrecord.com","journal-advocate.com","fortmorgantimes.com"].indexOf(t)?n(o="DENV/PMP Subscribers"):-1!==["dailybulletin.com","dailynews.com","presstelegram.com","ocregister.com","pasadenastarnews.com","pe.com","pressenterprise.com","redlandsdailyfacts.com","sbsun.com","sgvtribune.com","dailybreeze.com","whittierdailynews.com"].indexOf(t)?n(o="SCNG Subs"):-1!==["mercurynews.com","eastbaytimes.com","marinij.com","santacruzsentinel.com"].indexOf(t)&&n(o="BANG Subs")}),window.engageLibrary.mercurynewsIsMeteredArchive=(()=>{if(-1===e.host.search("mercurynews"))return console.log("archive check: not on mercurynews"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.ocregisterIsMeteredArchive=(()=>{if(-1===e.host.search("ocregister"))return console.log("archive check: not on ocregister"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.pressenterpriseIsMeteredArchive=(()=>{if(-1===e.host.search("pressenterprise"))return console.log("archive check: not on pressenterprise"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.eastbayIsMeteredArchive=(()=>{if(-1===e.host.search("eastbaytimes"))return console.log("archive check: not on eastbaytimes"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.marinijIsMeteredArchive=(()=>{if(-1===e.host.search("marinij"))return console.log("archive check: not on marinij"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.bostonheraldIsMeteredArchive=(()=>{if(-1===e.host.search("bostonherald"))return console.log("archive check: not on bostonherald"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.lowellsunIsMeteredArchive=(()=>{if(-1===e.host.search("lowellsun"))return console.log("archive check: not on lowellsun"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.sentinelIsMeteredArchive=(()=>{if(-1===e.host.search("sentinelandenterprise"))return console.log("archive check: not on sentinelandenterprise"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.dailyfreemanIsMeteredArchive=(()=>{if(-1===e.host.search("dailyfreeman"))return console.log("archive check: not on dailyfreeman"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.dailycameraIsMeteredArchive=(()=>{if(-1===e.host.search("dailycamera"))return console.log("archive check: not on dailycamera"),!1;const{today:n,expireDate:o}=t(),r=localStorage.getItem("abLocal");return n>o&&"B"===r||(console.log("archive check: has not been 90 days yet"),!1)}),window.engageLibrary.greeleytribuneIsMeteredArchive=(()=>{if(-1===e.host.search("greeleytribune"))return console.log("archive check: not on greeleytribune"),!1;const{today:n,expireDate:o}=t(),r=localStorage.getItem("abLocal");return n>o&&"B"===r||(console.log("archive check: has not been 90 days yet"),!1)}),window.engageLibrary.reporterheraldIsMeteredArchive=(()=>{if(-1===e.host.search("reporterherald"))return console.log("archive check: not on reporterherald"),!1;const{today:n,expireDate:o}=t(),r=localStorage.getItem("abLocal");return n>o&&"B"===r||(console.log("archive check: has not been 90 days yet"),!1)}),window.engageLibrary.timescallIsMeteredArchive=(()=>{if(-1===e.host.search("timescall"))return console.log("archive check: not on timescall"),!1;const{today:n,expireDate:o}=t(),r=localStorage.getItem("abLocal");return n>o&&"B"===r||(console.log("archive check: has not been 90 days yet"),!1)}),window.engageLibrary.santacruzsentinelIsMeteredArchive=(()=>{if(-1===e.host.search("santacruzsentinel"))return console.log("archive check: not on santacruzsentinel"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.montereyheraldIsMeteredArchive=(()=>{if(-1===e.host.search("montereyherald"))return console.log("archive check: not on montereyherald"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.chicoerIsMeteredArchive=(()=>{if(-1===e.host.search("chicoer"))return console.log("archive check: not on chicoer"),!1;const{today:n,expireDate:r}=t();return o(n,r)}),window.engageLibrary.articleSharingExpire=(()=>{const e=window.MNGAuthentication.articleShare;return 0!==e&&"null"!==e&&!1!==e&&""!==e}),window.engageLibrary.getRegwallSuccess=(()=>!!localStorage.getItem("regwallSuccess")&&"yes"),window.engageLibrary.getRegwallKnown=(()=>!!localStorage.getItem("regwallKnown")&&"yes"),window.engageLibrary.twinCitiesCheckBCForNonSub=(()=>{const e=decodeURIComponent(document.cookie).split(";");let t=0;for(t=0;tdocument.querySelector("main article").length>0&&document.querySelector("main article").hasClass("tag-all-readers")),window.engageLibrary.isOpinionPiece=(()=>{var e="Opinion",n=document.querySelector("article")?document.querySelector("article").classList:null;if(null==n)return!1;{e=e.split(",");let t=[];for(let[n,o]of e.entries())o=(o=(o=(o="tag-"+o).toLowerCase()).replaceAll(" ","-")).replaceAll("--","-"),t.push(o);for(let[e,o]of t.entries()){if(o+="",n.contains(o))return!0;if(e===t.length-1)return!1}}}),window.engageLibrary.profileDropDownExists=(()=>{document.getElementById("profileDropDown")}),window.engageLibrary.twinCitiesKnownEmail=(()=>n("Twincities - known email")),window.engageLibrary.twinCitiesUrlCheck=(()=>r(["twincities.com"])),window.engageLibrary.pmpUrlCheck=(()=>r(["greeleytribune.com","dailycamera.com","timescall.com","reporterherald.com"])),window.engageLibrary.paywallTimer=(()=>{var e=Date.now(),n=0;"undefined"!=typeof MNG_SSO_TOOLS_GLOBAL_START_TIME&&(n=e-MNG_SSO_TOOLS_GLOBAL_START_TIME),window.dataLayer.push({"Timer.PaywallShown":n}),performance.mark("connext_onPaywallShown")}),window.engageLibrary.inlineNewsletter=(()=>{console.log("hhhhhhhh");var e=jQuery(".Mg2-newsletter-inline_notif_mng .connext-email-input"),n=jQuery(".Mg2-newsletter-inline_notif_mng .connext-error-message"),t=jQuery(".Mg2-newsletter-inline_notif_mng .hide-on-success"),o=jQuery(".Mg2-newsletter-inline_notif_mng .show-on-success"),r=jQuery(".Mg2-newsletter-inline_notif_mng span[data-tmpl-action-name='Newsletter']").text(),a=jQuery(".Mg2-newsletter-inline_notif_mng div[data-tmpl-action-name='Success message']").html()||jQuery(".Mg2-newsletter-inline_notif_mng div[data-tmpl-action-name='Success message']").data("tmpl-action-value");jQuery(".Mg2-newsletter-inline_notif_mng span[data-tmpl-action-name='Error message']").html(),jQuery(document.body).on("click",".Mg2-newsletter-inline_notif_mng .submit",l=>{i(l,e,n,r,t,o,a)}),jQuery(document.body).on("input",".Mg2-newsletter-inline_notif_mng .connext-email-input",function(e){s({valid:!0})}),console.log("hhhhhhhhhhhhhhhhhhhh")}),window.engageLibrary.inlineRegwall1=(()=>{window.engageLibrary.paywallTimer();var e=jQuery("#registration__form .connext-email-input"),n=jQuery("#registration__form .connext-error-message"),t=jQuery("#registrationWall1 .hide-on-success"),o=jQuery("#registrationWall1 .show-on-success"),r=jQuery("#registrationWall1 .registrationWallID").text(),a=jQuery("#registration__form div[data-tmpl-action-name='Success message']").html()||jQuery("#registration__form div[data-tmpl-action-name='Success message']").data("tmpl-action-value");jQuery("#registration__form span[data-tmpl-action-name='Error message']").html(),jQuery(document.body).on("click","#registration__form .submit",l=>{i(l,e,n,r,t,o,a)}),jQuery(document.body).on("input","#registration__form .connext-email-input",function(t){s({valid:!0},n,e)})}),window.engageLibrary.inlineRegwall=(()=>{window.engageLibrary.paywallTimer();var e=jQuery("#registration__form .connext-email-input"),n=jQuery("#registration__form .connext-error-message"),t=jQuery("#registrationWall .hide-on-success"),o=jQuery("#registrationWall .show-on-success"),r=jQuery("#registrationWall .registrationWallID").text(),a=jQuery("#registration__form div[data-tmpl-action-name='Success message']").html()||jQuery("#registration__form div[data-tmpl-action-name='Success message']").data("tmpl-action-value");jQuery("#registration__form span[data-tmpl-action-name='Error message']").html(),jQuery(document.body).on("click","#registration__form .submit",l=>{i(l,e,n,r,t,o,a)}),jQuery(document.body).on("input","#registration__form .connext-email-input",function(t){s({valid:!0},n,e)})}),window.engageLibrary.expandCollapseJquery=(()=>{jQuery(document).ready(function(){var e=jQuery("[data-nxt-template-substep= 'Collapsed']"),n=jQuery("[data-nxt-template-substep= 'Expanded']"),t=jQuery(".collapse-button"),o=jQuery(".expand-button");t.on("click",function(){n.hide(),e.show()}),o.on("click",function(){n.show(),e.hide()})})}),window.engageLibrary.hybridHardwall=(()=>{window.engageLibrary.paywallTimer();var e=jQuery("#registration__form .connext-email-input"),n=jQuery("#registration__form .connext-error-message"),t=jQuery("#registrationWall .hide-on-success"),o=jQuery("#registrationWall .show-on-success"),r=jQuery("#registrationWallID").text(),a=jQuery("#registration__form div[data-tmpl-action-name='Success message']").html()||jQuery("#registration__form div[data-tmpl-action-name='Success message']").data("tmpl-action-value");jQuery("#registration__form span[data-tmpl-action-name='Error message']").html(),jQuery(document.body).on("click","#registration__form .submit",l=>{i(l,e,n,r,t,o,a)}),jQuery(document.body).on("input","#registration__form .connext-email-input",function(t){s({valid:!0},n,e)})}),window.engageLibrary.lowaLoginEvent=(()=>{window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"lowa_login_click",lowa_click:"login"})}),window.engageLibrary.lowaCloseEvent=(()=>{window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"lowa_login_click",lowa_click:"dismiss"})}),window.engageLibrary.whySubscribePageCheck=(()=>"why-subscribe"===window.location.pathname.split("/")[1]),window.engageLibrary.isSophiVariant=(()=>{const e=decodeURIComponent(function(e){const n=`${e}=`,t=decodeURIComponent(document.cookie).split(";");for(let e=0;ee.includes("TEST"));return!!e&&e.includes("-V")}),window.engageLibrary.shouldLoadPaywall=(()=>{if(e.hostname.includes("chicagotribune"))return"paywall"===g();{const e=d();return"wallType"in e&&"paywall"===e.wallType}}),window.engageLibrary.shouldLoadRegwall=(()=>{if(e.hostname.includes("chicagotribune"))return"regwall"===g();{const e=d();return"wallType"in e&&"regwall"===e.wallType}}),window.engageLibrary.responseIsNowall=(()=>{if(e.hostname.includes("chicagotribune"))return"nowall"===g();{const e=d();return"wallType"in e?"nowall"===e.wallType:"wallVisibility"in e&&"never"===e.wallVisibility}})};(async()=>{o(),console.log(`Engage Library loaded: ${(new Date).getTime()}`)})()}]); //# sourceMappingURL=engageLibrary.min.js.map;