/*! * Minimal Mistakes Jekyll Theme 4.25.1 by Michael Rose * Copyright 2013-2024 Michael Rose - mademistakes.com | @mmistakes * Free for personal and commercial use under the MIT license * https://github.com/mmistakes/minimal-mistakes/blob/master/LICENSE */ !function(e,t){"function"==typeof define&&define.amd?define([],function(){return t(e)}):"object"==typeof exports?module.exports=t(e):e.Gumshoe=t(e)}("undefined"!=typeof global?global:"undefined"!=typeof window?window:this,function(d){"use strict";function u(e){e&&e.sort(function(e,t){return o(e.content)=Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight)}function p(e,t){var n;e&&(n=e.nav.closest("li"))&&(n.classList.remove(t.navClass),e.content.classList.remove(t.contentClass),i(n,t),m("gumshoeDeactivate",n,{link:e.nav,content:e.content,settings:t}))}var f={navClass:"active",contentClass:"active",nested:!1,nestedClass:"active",offset:0,reflow:!1,events:!0},m=function(e,t,n){n.settings.events&&(e=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n}),t.dispatchEvent(e))},o=function(e){var t=0;if(e.offsetParent)for(;e;)t+=e.offsetTop,e=e.offsetParent;return 0<=t?t:0},g=function(e,t,n){e=e.getBoundingClientRect(),t="function"==typeof(t=t).offset?parseFloat(t.offset()):parseFloat(t.offset);return n?parseInt(e.bottom,10)<(d.innerHeight||document.documentElement.clientHeight):parseInt(e.top,10)<=t},h=function(e,t){return!(!n()||!g(e.content,t,!0))},i=function(e,t){t.nested&&(e=e.parentNode.closest("li"))&&(e.classList.remove(t.nestedClass),i(e,t))},v=function(e,t){t.nested&&(e=e.parentNode.closest("li"))&&(e.classList.add(t.nestedClass),v(e,t))};return function(e,t){function n(e){s&&d.cancelAnimationFrame(s),s=d.requestAnimationFrame(l.detect)}function o(e){s&&d.cancelAnimationFrame(s),s=d.requestAnimationFrame(function(){u(a),l.detect()})}var i,a,r,s,c,l={setup:function(){i=document.querySelectorAll(e),a=[],Array.prototype.forEach.call(i,function(e){var t=document.getElementById(decodeURIComponent(e.hash.substr(1)));t&&a.push({nav:e,content:t})}),u(a)}};l.detect=function(){var e,t,n,o=function(e,t){var n=e[e.length-1];if(h(n,t))return n;for(var o=e.length-1;0<=o;o--)if(g(e[o].content,t))return e[o]}(a,c);o?r&&o.content===r.content||(p(r,c),t=c,(e=o)&&(n=e.nav.closest("li"))&&(n.classList.add(t.navClass),e.content.classList.add(t.contentClass),v(n,t),m("gumshoeActivate",n,{link:e.nav,content:e.content,settings:t})),r=o):r&&(p(r,c),r=null)},l.destroy=function(){r&&p(r,c),d.removeEventListener("scroll",n,!1),c.reflow&&d.removeEventListener("resize",o,!1),c=s=r=i=a=null};return c=function(){var n={};return Array.prototype.forEach.call(arguments,function(e){for(var t in e){if(!e.hasOwnProperty(t))return;n[t]=e[t]}}),n}(f,t||{}),l.setup(),l.detect(),d.addEventListener("scroll",n,!1),c.reflow&&d.addEventListener("resize",o,!1),l}}),function(e,d){var o,t=e.jQuery||e.Cowboy||(e.Cowboy={});t.throttle=o=function(i,a,r,s){var c,l=0;function e(){var e=this,t=+new Date-l,n=arguments;function o(){l=+new Date,r.apply(e,n)}s&&!c&&o(),c&&clearTimeout(c),s===d&&ix

',t.appendChild(n.childNodes[1])),e&&a.extend(i,e),this.each(function(){var e=['iframe[src*="player.vimeo.com"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="kickstarter.com"][src*="video.html"]',"object","embed"],o=(i.customSelector&&e.push(i.customSelector),".fitvidsignore"),e=(i.ignore&&(o=o+", "+i.ignore),a(this).find(e.join(",")));(e=(e=e.not("object object")).not(o)).each(function(e){var t,n=a(this);0').parent(".fluid-width-video-wrapper").css("padding-top",100*t+"%"),n.removeAttr("height").removeAttr("width"))})})}}(window.jQuery||window.Zepto),$(function(){var n,o,e,i,t=$("nav.greedy-nav .greedy-nav__toggle"),a=$("nav.greedy-nav .visible-links"),r=$("nav.greedy-nav .hidden-links"),s=$("nav.greedy-nav"),c=$("nav.greedy-nav .site-logo"),l=$("nav.greedy-nav .site-logo img"),d=$("nav.greedy-nav .site-title"),u=$("nav.greedy-nav button.search__toggle");function p(){function t(e,t){o+=t,n+=1,i.push(o)}o=n=0,e=1e3,i=[],a.children().outerWidth(t),r.children().each(function(){var e;(e=(e=$(this)).clone()).css("visibility","hidden"),a.append(e),t(0,e.outerWidth()),e.remove()})}p();var f,m,g,h,v=$(window).width(),y=v<768?0:v<1024?1:v<1280?2:3;function w(){var e=(v=$(window).width())<768?0:v<1024?1:v<1280?2:3;e!==y&&p(),y=e,m=a.children().length,f=s.innerWidth()-(0!==c.length?c.outerWidth(!0):0)-d.outerWidth(!0)-(0!==u.length?u.outerWidth(!0):0)-(m!==i.length?t.outerWidth(!0):0),g=i[m-1],fi[m]&&(r.children().first().appendTo(a),m+=1,w()),t.attr("count",n-m),m===n?t.addClass("hidden"):t.removeClass("hidden")}$(window).resize(function(){w()}),t.on("click",function(){r.toggleClass("hidden"),$(this).toggleClass("close"),clearTimeout(h)}),r.on("mouseleave",function(){h=setTimeout(function(){r.addClass("hidden")},e)}).on("mouseenter",function(){clearTimeout(h)}),0===l.length||l[0].complete||0!==l[0].naturalWidth?w():l.one("load error",w)}),function(e){"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof exports?e(require("jquery")):e(window.jQuery||window.Zepto)}(function(l){function e(){}function d(e,t){m.ev.on("mfp"+e+S,t)}function u(e,t,n,o){var i=document.createElement("div");return i.className="mfp-"+e,n&&(i.innerHTML=n),o?t&&t.appendChild(i):(i=l(i),t&&i.appendTo(t)),i}function p(e,t){m.ev.triggerHandler("mfp"+e,t),m.st.callbacks&&(e=e.charAt(0).toLowerCase()+e.slice(1),m.st.callbacks[e])&&m.st.callbacks[e].apply(m,l.isArray(t)?t:[t])}function f(e){return e===n&&m.currTemplate.closeBtn||(m.currTemplate.closeBtn=l(m.st.closeMarkup.replace("%title%",m.st.tClose)),n=e),m.currTemplate.closeBtn}function a(){l.magnificPopup.instance||((m=new e).init(),l.magnificPopup.instance=m)}function r(){y&&(v.after(y.addClass(c)).detach(),y=null)}function i(){w&&l(document.body).removeClass(w)}function t(){i(),m.req&&m.req.abort()}var m,o,g,s,h,n,c,v,y,w,C="Close",$="BeforeClose",b="MarkupParse",I="Open",S=".mfp",E="mfp-ready",B="mfp-removing",k="mfp-prevent-close",x=!!window.jQuery,T=l(window),_=(l.magnificPopup={instance:null,proto:e.prototype={constructor:e,init:function(){var e=navigator.appVersion;m.isLowIE=m.isIE8=document.all&&!document.addEventListener,m.isAndroid=/android/gi.test(e),m.isIOS=/iphone|ipad|ipod/gi.test(e),m.supportsTransition=function(){var e=document.createElement("p").style,t=["ms","O","Moz","Webkit"];if(void 0!==e.transition)return!0;for(;t.length;)if(t.pop()+"Transition"in e)return!0;return!1}(),m.probablyMobile=m.isAndroid||m.isIOS||/(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent),g=l(document),m.popupsCache={}},open:function(e){if(!1===e.isObj){m.items=e.items.toArray(),m.index=0;for(var t,n=e.items,o=0;o(e||T.height())},_setFocus:function(){(m.st.focus?m.content.find(m.st.focus).eq(0):m.wrap).focus()},_onFocusIn:function(e){if(e.target!==m.wrap[0]&&!l.contains(m.wrap[0],e.target))return m._setFocus(),!1},_parseMarkup:function(i,e,t){var a;t.data&&(e=l.extend(t.data,e)),p(b,[i,e,t]),l.each(e,function(e,t){if(void 0===t||!1===t)return!0;var n,o;1<(a=e.split("_")).length?0<(n=i.find(S+"-"+a[0])).length&&("replaceWith"===(o=a[1])?n[0]!==t[0]&&n.replaceWith(t):"img"===o?n.is("img")?n.attr("src",t):n.replaceWith(l("").attr("src",t).attr("class",n.attr("class"))):n.attr(a[1],t)):i.find(S+"-"+e).html(t)})},_getScrollbarSize:function(){var e;return void 0===m.scrollbarSize&&((e=document.createElement("div")).style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(e),m.scrollbarSize=e.offsetWidth-e.clientWidth,document.body.removeChild(e)),m.scrollbarSize}},modules:[],open:function(e,t){return a(),(e=e?l.extend(!0,{},e):{}).isObj=!0,e.index=t||0,this.instance.open(e)},close:function(){return l.magnificPopup.instance&&l.magnificPopup.instance.close()},registerModule:function(e,t){t.options&&(l.magnificPopup.defaults[e]=t.options),l.extend(this.proto,t.proto),this.modules.push(e)},defaults:{disableOn:0,key:null,midClick:!1,mainClass:"",preloader:!0,focus:"",closeOnContentClick:!1,closeOnBgClick:!0,closeBtnInside:!0,showCloseBtn:!0,enableEscapeKey:!0,modal:!1,alignTop:!1,removalDelay:0,prependTo:null,fixedContentPos:"auto",fixedBgPos:"auto",overflowY:"auto",closeMarkup:'',tClose:"Close (Esc)",tLoading:"Loading...",autoFocusLast:!0}},l.fn.magnificPopup=function(e){a();var t,n,o,i=l(this);return"string"==typeof e?"open"===e?(t=x?i.data("magnificPopup"):i[0].magnificPopup,n=parseInt(arguments[1],10)||0,o=t.items?t.items[n]:(o=i,(o=t.delegate?o.find(t.delegate):o).eq(n)),m._openClick({mfpEl:o},i,t)):m.isOpen&&m[e].apply(m,Array.prototype.slice.call(arguments,1)):(e=l.extend(!0,{},e),x?i.data("magnificPopup",e):i[0].magnificPopup=e,m.addGroup(i,e)),i},"inline"),O=(l.magnificPopup.registerModule(_,{options:{hiddenClass:"hide",markup:"",tNotFound:"Content not found"},proto:{initInline:function(){m.types.push(_),d(C+"."+_,function(){r()})},getInline:function(e,t){var n,o,i;return r(),e.src?(n=m.st.inline,(o=l(e.src)).length?((i=o[0].parentNode)&&i.tagName&&(v||(c=n.hiddenClass,v=u(c),c="mfp-"+c),y=o.after(v).detach().removeClass(c)),m.updateStatus("ready")):(m.updateStatus("error",n.tNotFound),o=l("
")),e.inlineElement=o):(m.updateStatus("ready"),m._parseMarkup(t,{},e),t)}}}),"ajax");l.magnificPopup.registerModule(O,{options:{settings:null,cursor:"mfp-ajax-cur",tError:'The content could not be loaded.'},proto:{initAjax:function(){m.types.push(O),w=m.st.ajax.cursor,d(C+"."+O,t),d("BeforeChange."+O,t)},getAjax:function(o){w&&l(document.body).addClass(w),m.updateStatus("loading");var e=l.extend({url:o.src,success:function(e,t,n){e={data:e,xhr:n};p("ParseAjax",e),m.appendContent(l(e.data),O),o.finished=!0,i(),m._setFocus(),setTimeout(function(){m.wrap.addClass(E)},16),m.updateStatus("ready"),p("AjaxContentAdded")},error:function(){i(),o.finished=o.loadError=!0,m.updateStatus("error",m.st.ajax.tError.replace("%url%",o.src))}},m.st.ajax.settings);return m.req=l.ajax(e),""}}});var P;l.magnificPopup.registerModule("image",{options:{markup:'
',cursor:"mfp-zoom-out-cur",titleSrc:"title",verticalFit:!0,tError:'The image could not be loaded.'},proto:{initImage:function(){var e=m.st.image,t=".image";m.types.push("image"),d(I+t,function(){"image"===m.currItem.type&&e.cursor&&l(document.body).addClass(e.cursor)}),d(C+t,function(){e.cursor&&l(document.body).removeClass(e.cursor),T.off("resize"+S)}),d("Resize"+t,m.resizeImage),m.isLowIE&&d("AfterChange",m.resizeImage)},resizeImage:function(){var e,t=m.currItem;t&&t.img&&m.st.image.verticalFit&&(e=0,m.isLowIE&&(e=parseInt(t.img.css("padding-top"),10)+parseInt(t.img.css("padding-bottom"),10)),t.img.css("max-height",m.wH-e))},_onImageHasSize:function(e){e.img&&(e.hasSize=!0,P&&clearInterval(P),e.isCheckingImgSize=!1,p("ImageHasSize",e),e.imgHidden)&&(m.content&&m.content.removeClass("mfp-loading"),e.imgHidden=!1)},findImageSize:function(t){function n(e){P&&clearInterval(P),P=setInterval(function(){0
',srcAction:"iframe_src",patterns:{youtube:{index:"youtube.com",id:"v=",src:"//www.youtube.com/embed/%id%?autoplay=1"},vimeo:{index:"vimeo.com/",id:"/",src:"//player.vimeo.com/video/%id%?autoplay=1"},gmaps:{index:"//maps.google.",src:"%id%&output=embed"}}},proto:{initIframe:function(){m.types.push(A),d("BeforeChange",function(e,t,n){t!==n&&(t===A?M():n===A&&M(!0))}),d(C+"."+A,function(){M()})},getIframe:function(e,t){var n=e.src,o=m.st.iframe,i=(l.each(o.patterns,function(){if(-1',preload:[0,2],navigateByImgClick:!0,arrows:!0,tPrev:"Previous (Left arrow key)",tNext:"Next (Right arrow key)",tCounter:"%curr% of %total%"},proto:{initGallery:function(){var a=m.st.gallery,e=".mfp-gallery";if(m.direction=!0,!a||!a.enabled)return!1;h+=" mfp-gallery",d(I+e,function(){a.navigateByImgClick&&m.wrap.on("click"+e,".mfp-img",function(){if(1=m.index,m.index=e,m.updateItemHTML()},preloadNearbyImages:function(){for(var e=m.st.gallery.preload,t=Math.min(e[0],m.items.length),n=Math.min(e[1],m.items.length),o=1;o<=(m.direction?n:t);o++)m._preloadItem(m.index+o);for(o=1;o<=(m.direction?t:n);o++)m._preloadItem(m.index-o)},_preloadItem:function(e){var t;e=L(e),m.items[e].preloaded||((t=m.items[e]).parsed||(t=m.parseEl(e)),p("LazyLoad",t),"image"===t.type&&(t.img=l('').on("load.mfploader",function(){t.hasSize=!0}).on("error.mfploader",function(){t.hasSize=!0,t.loadError=!0,p("LazyLoadError",t)}).attr("src",t.src)),t.preloaded=!0)}}}),"retina");l.magnificPopup.registerModule(H,{options:{replaceSrc:function(e){return e.src.replace(/\.\w+$/,function(e){return"@2x"+e})},ratio:1},proto:{initRetina:function(){var n,o;1t.durationMax?t.durationMax:t.durationMin&&e=c)return C.cancelScroll(!0),e=t,n=h,0===(t=o)&&document.body.focus(),n||(t.focus(),document.activeElement!==t&&(t.setAttribute("tabindex","-1"),t.focus(),t.style.outline="none"),b.scrollTo(0,e)),S("scrollStop",g,o,i),!(w=u=null)},m=function(e){var t,n,o;l+=e-(u=u||e),p=a+s*(n=1<(p=0===d?0:l/d)?1:p,"easeInQuad"===(t=g).easing&&(o=n*n),"easeOutQuad"===t.easing&&(o=n*(2-n)),"easeInOutQuad"===t.easing&&(o=n<.5?2*n*n:(4-2*n)*n-1),"easeInCubic"===t.easing&&(o=n*n*n),"easeOutCubic"===t.easing&&(o=--n*n*n+1),"easeInOutCubic"===t.easing&&(o=n<.5?4*n*n*n:(n-1)*(2*n-2)*(2*n-2)+1),"easeInQuart"===t.easing&&(o=n*n*n*n),"easeOutQuart"===t.easing&&(o=1- --n*n*n*n),"easeInOutQuart"===t.easing&&(o=n<.5?8*n*n*n*n:1-8*--n*n*n*n),"easeInQuint"===t.easing&&(o=n*n*n*n*n),"easeOutQuint"===t.easing&&(o=1+--n*n*n*n*n),"easeInOutQuint"===t.easing&&(o=n<.5?16*n*n*n*n*n:1+16*--n*n*n*n*n),(o=t.customEasing?t.customEasing(n):o)||n),b.scrollTo(0,Math.floor(p)),f(p,r)||(w=b.requestAnimationFrame(m),u=e)},0===b.pageYOffset&&b.scrollTo(0,0),e=o,t=g,h||history.pushState&&t.updateURL&&history.pushState({smoothScroll:JSON.stringify(t),anchor:e.id},document.title,e===document.documentElement?"#top":"#"+e.id),"matchMedia"in b&&b.matchMedia("(prefers-reduced-motion)").matches?b.scrollTo(0,Math.floor(r)):(S("scrollStart",g,o,i),C.cancelScroll(!0),b.requestAnimationFrame(m)))},C.destroy=function(){v&&(document.removeEventListener("click",t,!1),b.removeEventListener("popstate",n,!1),C.cancelScroll(),w=y=i=v=null)};if("querySelector"in document&&"addEventListener"in b&&"requestAnimationFrame"in b&&"closest"in b.Element.prototype)return C.destroy(),v=I(E,e||{}),y=v.header?document.querySelector(v.header):null,document.addEventListener("click",t,!1),v.updateURL&&v.popstate&&b.addEventListener("popstate",n,!1),C;throw"Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs."}}),$(function(){$("#main").fitVids();function e(){(0===$(".author__urls-wrapper").find("button").length?1024<$(window).width():!$(".author__urls-wrapper").find("button").is(":visible"))?$(".sidebar").addClass("sticky"):$(".sidebar").removeClass("sticky")}e(),$(window).resize(function(){e()}),$(".author__urls-wrapper").find("button").on("click",function(){$(".author__urls").toggleClass("is--visible"),$(".author__urls-wrapper").find("button").toggleClass("open")}),$(document).keyup(function(e){27===e.keyCode&&$(".initial-content").hasClass("is--hidden")&&($(".search-content").toggleClass("is--visible"),$(".initial-content").toggleClass("is--hidden"))}),$(".search__toggle").on("click",function(){$(".search-content").toggleClass("is--visible"),$(".initial-content").toggleClass("is--hidden"),setTimeout(function(){$(".search-content").find("input").focus()},400)}),new SmoothScroll('a[href*="#"]',{offset:20,speed:400,speedAsDuration:!0,durationMax:500});0<$("nav.toc").length&&new Gumshoe("nav.toc a",{navClass:"active",contentClass:"active",nested:!1,nestedClass:"active",offset:20,reflow:!0,events:!0}),document.addEventListener("gumshoeActivate",function(e){var e=e.target,t={behavior:"auto",block:"nearest",inline:"start"},n=document.querySelector("aside.sidebar__right.sticky");n&&"sticky"===window.getComputedStyle(n).position&&(e.parentElement.classList.contains("toc__menu")&&e==e.parentElement.firstElementChild?document.querySelector("nav.toc header"):e).scrollIntoView(t)}),$("a[href$='.jpg'],a[href$='.jpeg'],a[href$='.JPG'],a[href$='.png'],a[href$='.gif'],a[href$='.webp']").has("> img").addClass("image-popup"),$(".image-popup").magnificPopup({type:"image",tLoading:"Loading image #%curr%...",gallery:{enabled:!0,navigateByImgClick:!0,preload:[0,1]},image:{tError:'Image #%curr% could not be loaded.'},removalDelay:500,mainClass:"mfp-zoom-in",callbacks:{beforeOpen:function(){this.st.image.markup=this.st.image.markup.replace("mfp-figure","mfp-figure mfp-with-anim")}},closeOnContentClick:!0,midClick:!0}),$(".page__content").find("h1, h2, h3, h4, h5, h6").each(function(){var e,t=$(this).attr("id");t&&((e=document.createElement("a")).className="header-link",e.href="#"+t,e.innerHTML='Permalink',e.title="Permalink",$(this).append(e))})});