"use strict";function setCookie(e,t,n){const s=new Date;s.setTime(s.getTime()+864e5*n),document.cookie=e+"="+t+";path=/;expires="+s.toGMTString()}function getCookie(e){e=document.cookie.match("(^|;) ?"+e+"=([^;]*)(;|$)");return e?e[2]:null}function analyticsTrackingEvent(e,t,n,s,o,i){"undefined"!=typeof wp&&(t="Site Message: "+t.charAt(0).toUpperCase()+t.slice(1),wp.hooks.doAction("wpMessageInserterAnalyticsEvent",e,t,n,s,o,i))}function setCurrentCount(){let e=getCookie("count");var t=Math.floor((new Date).getTime()/1e3);getCookie("count")?t>getCookie("timecheck")&&(setCookie("timecheck",t+3600,30),setCookie("count",++e,30)):(setCookie("count",1,30),setCookie("timecheck",t+3600,30));const n=new URLSearchParams(window.location.search);return e=null!==n.get("count")?parseInt(n.get("count")):e}function getPostId(e){let t=0;return e.classList.forEach(function(e){if(0{let t=e.target;do{if(t===n)return}while(t=t.parentNode);hidePopup(n,s,c,"Click Outside to Close")}),document.onkeydown=function(e){e=e||window.event;let t=!1;(t="key"in e?"Escape"===e.key||"Esc"===e.key:27===e.keyCode)&&hidePopup(n,s,c,"Escape Key")})}function messageAnalytics(e){const n=getMessageRegion(e),s=getPostId(e);"none"!==window.getComputedStyle(e,null).display&&(analyticsTrackingEvent("event",n,"Show",s,void 0,1),e.addEventListener("click",function(e){var t=e.target.classList.contains("message-login"),e=e.target.classList.contains("sm-close-btn");!0===t?(t=$(this).attr("href"),analyticsTrackingEvent("event",n,"Login Link",t)):!1===e&&analyticsTrackingEvent("event",n,"Click",s)},!0))}document.addEventListener("DOMContentLoaded",function(){const s="wp-message-inserter-message-region-popup",o="sm-shown";var e="check-session-message";const i="validated",t=document.querySelectorAll("."+e);if(0e.json()).then(e=>{if(!0===e.success){switch(a="info",c.innerHTML="Thanks",e.data.user_status){case"existing":o="Update";break;case"new":case"pending":o="Signup"}""!==e.data.confirm_message&&(s=e.data.confirm_message),d("event",n,o,location.pathname),p(n,i,m,o)}else a="error",c.disabled=!1,c.innerHTML=t,d("event",n,"Fail",location.pathname),p(n,i,m,"Fail"),""!==e.data.confirm_message&&(s=e.data.confirm_message);l.innerHTML=s,l.classList.add("m-form-message-"+a),l.classList.remove("m-form-message-ajax-placeholder"),r.classList.add("m-form-minnpost-form-processor-mailchimp-submitted"),r.classList.contains("m-form-fullpage")&&l.scrollIntoView({behavior:"smooth"})}).catch(e=>{l.innerHTML="

An error has occured. Please try again.

",l.classList.add("m-form-message-error"),l.classList.remove("m-form-message-ajax-placeholder"),r.classList.remove("m-form-minnpost-form-processor-mailchimp-submitted"),c.disabled=!1,c.innerHTML=t,d("event","Newsletter","Fail",location.pathname),p(n,i,m,"Fail")})})})})}();; function copyToClipboard( element ) { var $temp = jQuery( '' ); jQuery( 'body' ).append( $temp ); $temp.val( jQuery( element ).text() ).select(); document.execCommand( 'copy' ); $temp.remove(); } function modal_actions(){ // Remove captions from shareable text var $ = jQuery; var $shareable = $('#republication-tracker-tool-shareable-content'); var html = $shareable.text(); var parser = new DOMParser(); var doc = parser.parseFromString(html, "text/html"); $(doc).find('.wp-caption').remove(); var captionless = $(doc).find('body').html(); $shareable.html(captionless); // Responsive modal var $modal = $('#republication-tracker-tool-modal'); var $btn = $('.republication-tracker-tool-button'); var $close = $('.republication-tracker-tool-close'); // url hash of #show-republish: open the modal if ( '#show-republish' === window.location.hash ) { show_modal( $modal ); } // click the republish button: open the modal $btn.click(function(){ show_modal( $modal ); }); // click on the modal: close the modal $modal.click(function(){ close_modal( $modal ); }); // close button click: close the modal $close.click(function(){ close_modal( $modal ); }); // escape key press: close the modal $(document).keyup(function(e) { if (27 === e.keyCode) { close_modal( $modal ); } }); } function show_modal( $modal ) { var $ = jQuery; var $modal_content = $('#republication-tracker-tool-modal-content'); //$modal.html( html ); $modal.show(); $modal_content.show(); $('body').addClass('modal-open-disallow-scrolling'); $('#republication-tracker-tool-modal-content').unbind().click(function(e) { e.stopPropagation(); }); } function close_modal( $modal ) { var $ = jQuery; $('body').removeClass('modal-open-disallow-scrolling'); $modal.hide(); } jQuery(document).ready(function(){ var $ = jQuery, postId = $( '#republication-tracker-tool-modal' ).attr( 'data-postid' ), pluginsdir = $( '#republication-tracker-tool-modal' ).attr( 'data-pluginsdir' ); $('#republication-tracker-tool-modal').append($('#republication-tracker-tool-modal-content')); $('body').append($('#republication-tracker-tool-modal')); modal_actions(); }); ; !function(f){"use strict";function d(n){document.addEventListener("mouseover",function(e){var t=e.target,e=n(t);(e=e||(t=t.parentElement)&&n(t))&&d.show(t,e,!0)})}function u(e){return function(e){if(Array.isArray(e))return a(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Map"===(n="Object"===n&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);nwindow.innerHeight?(c="s",n()):"e"===c&&t.left<0?(c="w",n()):"w"===c&&t.right>window.innerWidth&&(c="e",n()),s.className+=" tlite-visible",s}(a,l,r)}t=t||{},(e.tooltip||(r=t,(a=e).addEventListener("mousedown",c),a.addEventListener("mouseleave",c),a.tooltip={show:function(){l=a.title||a.getAttribute(s)||l,a.title="",a.setAttribute(s,""),l&&!o&&(o=setTimeout(u,n?150:1))},hide:function(e){n===e&&(o=clearTimeout(o),(e=i&&i.parentNode)&&e.removeChild(i),i=void 0)}})).show()},d.hide=function(e,t){e.tooltip&&e.tooltip.hide(t)},"undefined"!=typeof module&&module.exports&&(module.exports=d);function t(){var e=0'}function v(){document.querySelectorAll("[data-autoresize]").forEach(function(e){e.style.boxSizing="border-box";var t=e.offsetHeight-e.clientHeight;e.addEventListener("input",function(e){e.target.style.height="auto",e.target.style.height=e.target.scrollHeight+t+"px"}),e.removeAttribute("data-autoresize")})}!function a(r,i,o){function l(t,e){if(!i[t]){if(!r[t]){var n="function"==typeof require&&require;if(!e&&n)return n(t,!0);if(s)return s(t,!0);throw(n=new Error("Cannot find module '"+t+"'")).code="MODULE_NOT_FOUND",n}n=i[t]={exports:{}},r[t][0].call(n.exports,function(e){return l(r[t][1][e]||e)},n,n.exports,a,r,i,o)}return i[t].exports}for(var s="function"==typeof require&&require,e=0;e a");null!==o&&o.addEventListener("click",function(e){e.preventDefault();e="true"===this.getAttribute("aria-expanded")||!1;this.setAttribute("aria-expanded",!e),!0==e?i.transitionHide():i.transitionShow()});var e,t,n,l,s=document.querySelector("nav .m-form-search fieldset .a-button-sentence");null!==s&&((e=document.createElement("div")).innerHTML='',t=document.createDocumentFragment(),e.setAttribute("class","a-close-holder"),t.appendChild(e),s.appendChild(t),n=c({element:document.querySelector(".m-menu-primary-actions .m-form-search"),visibleClass:"is-open",displayValue:"flex"}),(l=document.querySelector("li.search > a")).addEventListener("click",function(e){e.preventDefault();e="true"===l.getAttribute("aria-expanded")||!1;l.setAttribute("aria-expanded",!e),!0==e?n.transitionHide():n.transitionShow()}),document.querySelector(".a-close-search").addEventListener("click",function(e){e.preventDefault();e="true"===l.getAttribute("aria-expanded")||!1;l.setAttribute("aria-expanded",!e),!0==e?n.transitionHide():n.transitionShow()})),document.onkeydown=function(e){var t,n;("key"in(e=e||window.event)?"Escape"===e.key||"Esc"===e.key:27===e.keyCode)&&(t="true"===r.getAttribute("aria-expanded")||!1,n="true"===o.getAttribute("aria-expanded")||!1,e="true"===l.getAttribute("aria-expanded")||!1,void 0!==m(t)&&!0==t&&(r.setAttribute("aria-expanded",!t),a.transitionHide()),void 0!==m(n)&&!0==n&&(o.setAttribute("aria-expanded",!n),i.transitionHide()),void 0!==m(e)&&!0==e&&(l.setAttribute("aria-expanded",!e),searchTransitioner.transitionHide()))}}(),document.querySelectorAll(".m-sub-navigation").forEach(function(e){t({selector:e,navSelector:".m-subnav-navigation",contentSelector:".m-menu-sub-navigation",itemSelector:"li, a",buttonLeftSelector:".nav-scroller-btn--left",buttonRightSelector:".nav-scroller-btn--right"})}),document.querySelectorAll(".m-pagination-navigation").forEach(function(e){t({selector:e,navSelector:".m-pagination-container",contentSelector:".m-pagination-list",itemSelector:"li, a",buttonLeftSelector:".nav-scroller-btn--left",buttonRightSelector:".nav-scroller-btn--right"})}),document.querySelectorAll(".o-site-sidebar a").forEach(function(o){return o.addEventListener("click",function(e){var t=o.closest(".m-widget"),n=o.closest(".m-zone"),a="",r="",i="";null!==t?a=t.querySelector("h3").textContent:null!==n&&(r=n.querySelector(".a-zone-title").textContent),null!==a?i=a:null!==r&&(i=r),l("event","Sidebar Link","Click",i)})}),document.querySelectorAll(".m-related a").forEach(function(e){return e.addEventListener("click",function(e){l("event","Related Section Link","Click",location.pathname)})}),jQuery.fn.textNodes=function(){return this.contents().filter(function(){return this.nodeType===Node.TEXT_NODE&&""!==this.nodeValue.trim()})},f(document).ajaxStop(function(){null!==document.querySelector("#llc_comments")&&v()}),document.addEventListener("DOMContentLoaded",function(e){var t,n,a,r,i,o,l,s,c,u,d,m;0 li").length,f(".m-user-email-list").on("click",'.a-form-caption.a-make-primary-email input[type="radio"]',function(){t=f(this).val(),n=f("#email").val(),a=f(this).prop("id").replace("primary_email_",""),s=p("primary-change"),m=f(this).parent().parent(),f(".a-pre-confirm",m).hide(),f(".a-form-confirm",m).show(),f(this).parent().parent().addClass("a-pre-confirm"),f(this).parent().parent().removeClass("a-stop-confirm"),f(this).parent().parent().append(s),f(".m-user-email-list").on("click","#a-confirm-primary-change",function(e){e.preventDefault(),f(".m-user-email-list > li").textNodes().first().replaceWith(t),f("#user-email-"+a).textNodes().first().replaceWith(n),f("#email").val(t),o.submit(),f('.a-form-caption.a-make-primary-email input[type="radio"]').prop("checked",!1),f("#primary_email_"+a).val(n),f("#remove_email_"+a).val(n),f(".a-form-confirm",m.parent()).remove(),f(".a-pre-confirm",m.parent()).show()}),f(".m-user-email-list").on("click","#a-stop-primary-change",function(e){e.preventDefault(),f(".a-pre-confirm",m.parent()).show(),f(".a-form-confirm",m.parent()).remove()})}),f(".m-user-email-list").on("change",'.a-form-caption.a-remove-email input[type="checkbox"]',function(){r=f(this).val(),s=p("removal"),f(".m-user-email-list > li").each(function(){f(this).contents().get(0).nodeValue!==r&&u.push(f(this).contents().get(0).nodeValue)}),m=f(this).parent().parent(),f(".a-pre-confirm",m).hide(),f(".a-form-confirm",m).show(),f(this).parent().parent().addClass("a-pre-confirm"),f(this).parent().parent().removeClass("a-stop-confirm"),f(this).parent().parent().append(s),f(".m-user-email-list").on("click","#a-confirm-removal",function(e){e.preventDefault(),f(this).parents("li").fadeOut("normal",function(){f(this).remove()}),f("#_consolidated_emails").val(u.join(",")),c=f(".m-user-email-list > li").length,o.submit(),f(".a-form-confirm",m.parent()).remove()}),f(".m-user-email-list").on("click","#a-stop-removal",function(e){e.preventDefault(),f(".a-pre-confirm",m.parent()).show(),f(".a-form-confirm",m.parent()).remove()})})),f(".m-form-email").on("click",".a-form-caption.a-add-email",function(e){e.preventDefault(),f(".a-form-caption.a-add-email").before('
'),c++}),f("input[type=submit]").click(function(){var e=f(this);e.closest("form").data("submitting_button",e.val())}),f(".m-entry-content").on("submit","#account-settings-form",function(e){var t=f(this),n=t.data("submitting_button")||"";""!==n&&"Save Changes"===n||(e.preventDefault(),d=t.serialize(),d+="&rest=true",f.ajax({url:l,type:"post",beforeSend:function(e){e.setRequestHeader("X-WP-Nonce",user_account_management_rest.nonce)},dataType:"json",data:d}).done(function(){i=f('input[name="_consolidated_emails_array[]"]').map(function(){return f(this).val()}).get(),f.each(i,function(e,t){c+=e,f(".m-user-email-list").append('
  • '+t+'
  • '),f("#_consolidated_emails").val(f("#_consolidated_emails").val()+","+t)}),f(".m-form-change-email .a-input-with-button").remove(),0===f(".m-user-email-list").length&&f('input[name="_consolidated_emails_array[]"]')!==f('input[name="email"]')&&location.reload()}))})),null!==document.querySelector("[data-autoresize]")&&v()}),document.querySelectorAll(".m-form").forEach(function(e){ValidForm(e,{validationErrorParentClass:"m-has-validation-error",validationErrorClass:"a-validation-error",invalidClass:"a-error",errorPlacement:"after"})});var r=f(".m-form");function n(e,t,n){var a="",r="",i="",o="",a="1"===n?"On":"0"===n?"Off":"Click";l("event",(r=!0===e?"Always ":r)+"Show Comments"+(i=""!==(o=t.replace("always-show-comments-",""))?" - "+(o=o.charAt(0).toUpperCase()+o.slice(1)):i),a,location.pathname)}r.find(":input").on("invalid",function(){var e=f(this),t=r.find(".a-error").first(),n=t.parent();if(e[0]===t[0]){t=n.offset().top,n=window.pageYOffset;if(n',n=document.createDocumentFragment(),t.setAttribute("class","a-close-holder"),n.appendChild(t),e.appendChild(n))}}(e)}),document.querySelectorAll(".m-event-datetime a").forEach(function(e){var t,n;e=(t=e).closest(".m-event-date-and-calendar"),n=c({element:e.querySelector(".a-events-cal-links"),visibleClass:"a-events-cal-link-visible",displayValue:"block"}),null!==t&&(t.addEventListener("click",function(e){e.preventDefault();e="true"===t.getAttribute("aria-expanded")||!1;t.setAttribute("aria-expanded",!e),!0==e?n.transitionHide():n.transitionShow()}),null!==(e=e.querySelector(".a-close-calendar"))&&e.addEventListener("click",function(e){e.preventDefault();e="true"===t.getAttribute("aria-expanded")||!1;t.setAttribute("aria-expanded",!e),!0==e?n.transitionHide():n.transitionShow()}))})}(jQuery);;