vendor: 6,516 bytes, lines 1-132
1/* --- $MAGNIFIC POPUP --- */ 2 3/*! Magnific Popup - v1.1.0 - 2016-02-20 4 * http://dimsemenov.com/plugins/magnific-popup/ 5 * Copyright (c) 2016 Dmitry Semenov; */ 6; 7! function (a) { 8 "function" == typeof define && define.amd ? define(["jquery"], a) : a("object" == typeof exports ? require("jquery") : window.jQuery || window.Zepto) 9}(function (a) { 10 var post_title = MagnificPopupItems.post_title; 11 var b, c, d, e, f, g, h = "Close", 12 i = "BeforeClose", 13 j = "AfterClose", 14 k = "BeforeAppend", 15 l = "MarkupParse", 16 m = "Open", 17 n = "Change", 18 o = "mfp", 19 p = "." + o, 20 q = "mfp-ready", 21 r = "mfp-removing", 22 s = "mfp-prevent-close", 23 t = function () {}, 24 u = !!window.jQuery, 25 v = a(window), 26 w = function (a, c) { 27 b.ev.on(o + a + p, c) 28 }, 29 x = function (b, c, d, e) { 30 window.location.hash="gallery"; 31 var f = document.createElement("div"); 32 return f.className = "mfp-" + b, d && (f.innerHTML = d), e ? c && c.appendChild(f) : (f = a(f), c && f.appendTo(c)), f 33 }, 34 y = function (c, d) { 35 b.ev.triggerHandler(o + c, d), b.st.callbacks && (c = c.charAt(0).toLowerCase() + c.slice(1), b.st.callbacks[c] && b.st.callbacks[c].apply(b, a.isArray(d) ? d : [d])) 36 }, 37 z = function (c) { 38 return c === g && b.currTemplate.closeBtn || (b.currTemplate.closeBtn = a(b.st.closeMarkup.replace("%title%", b.st.tClose)), g = c), b.currTemplate.closeBtn 39 }, 40 A = function () { 41 a.magnificPopup.instance || (b = new t, b.init(), a.magnificPopup.instance = b) 42 }, 43 B = function () { 44 var a = document.createElement("p").style, 45 b = ["ms", "O", "Moz", "Webkit"]; 46 if (void 0 !== a.transition) return !0; 47 for (; b.length;) 48 if (b.pop() + "Transition" in a) return !0; 49 return !1 50 }; 51 t.prototype = { 52 constructor: t, 53 init: function () { 54 var c = navigator.appVersion; 55 b.isLowIE = b.isIE8 = document.all && !document.addEventListener, b.isAndroid = /android/gi.test(c), b.isIOS = /iphone|ipad|ipod/gi.test(c), b.supportsTransition = B(), b.probablyMobile = b.isAndroid || b.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent), d = a(document), b.popupsCache = {} 56 }, 57 open: function (c) { 58 var e; 59 if (c.isObj === !1) { 60 b.items = c.items.toArray(), b.index = 0; 61 var g, h = c.items; 62 for (e = 0; e < h.length; e++) 63 if (g = h[e], g.parsed && (g = g.el[0]), g === c.el[0]) { 64 b.index = e; 65 break 66 } 67 } else b.items = a.isArray(c.items) ? c.items : [c.items], b.index = c.index || 0; 68 if (b.isOpen) return void b.updateItemHTML(); 69 b.types = [], 70 f = "", 71 c.mainEl && c.mainEl.length ? b.ev = c.mainEl.eq(0) : b.ev = d, 72 c.key ? (b.popupsCache[c.key] || (b.popupsCache[c.key] = {}), 73 b.currTemplate = b.popupsCache[c.key]) : b.currTemplate = {}, 74 b.st = a.extend(!0, {}, a.magnificPopup.defaults, c), 75 b.fixedConteironos = "auto" === b.st.fixedConteironos ? !b.probablyMobile : b.st.fixedConteironos, 76 b.st.modal && (b.st.closeOnContentClick = !1, 77 b.st.closeOnBgClick = !1, 78 b.st.showCloseBtn = !1, 79 b.st.enableEscapeKey = !1), 80 b.bgOverlay || (b.bgOverlay = x("bg").on("click" + p, function () { 81 b.close() 82 }), 83 b.wrap = x("wrap").attr("tabindex", -1).on("click" + p, function (a) { 84 b._checkIfClose(a.target) && b.close() 85 }), 86 b.container = x("container", b.wrap)), 87 b.contentContainer = x("content"), 88 b.st.preloader && (b.preloader = x("preloader", b.container, b.st.tLoading)); 89 // console.log("container:",b.container); 90 // var vh = window.innerHeight * 0.01; 91 // console.log('--vh:',vh); 92 // Then we set the value in the --vh custom property to the root of the document 93 // document.documentElement.style.setProperty('--vh', vh+'px'); 94 // var topbar = document.querySelector('.article__title.article__title--single'); 95 // console.log('topbar:',topbar); 96 // topbar.innerText = vh; 97 var i = a.magnificPopup.modules; 98 for (e = 0; e < i.length; e++) { 99 var j = i[e]; 100 j = j.charAt(0).toUpperCase() + j.slice(1), b["init" + j].call(b) 101 } 102 y("BeforeOpen"), b.st.showCloseBtn && (b.st.closeBtnInside ? (w(l, function (a, b, c, d) { 103 c.close_replaceWith = z(d.type) 104 }), f += " mfp-close-btn-in") : b.wrap.append(z())), b.st.alignTop && (f += " mfp-align-top"), b.fixedConteironos ? b.wrap.css({ 105 overflow: b.st.overflowY, 106 overflowX: "hidden", 107 overflowY: b.st.overflowY 108 }) : b.wrap.css({ 109 top: v.scrollTop(), 110 position: "absolute" 111 }), (b.st.fixedBgPos === !1 || "auto" === b.st.fixedBgPos && !b.fixedConteironos) && b.bgOverlay.css({ 112 height: d.height(), 113 position: "absolute" 114 }), b.st.enableEscapeKey && d.on("keyup" + p, function (a) { 115 27 === a.keyCode && b.close() 116 }), v.on("resize" + p, function () { 117 b.updateSize() 118 }), b.st.closeOnContentClick || (f += " mfp-auto-cursor"), f && b.wrap.addClass(f); 119 var k = b.wH = v.height(), 120 n = {}; 121 if (b.fixedConteironos && b._hasScrollBar(k)) { 122 var o = b._getScrollbarSize(); 123 o && (n.marginRight = o) 124 } 125 126 b.fixedConteironos && (b.isIE7 ? a("body, html").css("overflow", "hidden") : n.overflow = "hidden"); 127 // document.querySelector('html').style.overflow='hidden'; 128 129 a('html').addClass('noscroll'); 130 131 var r = b.st.mainClass; 132 return b.isIE7 && (r += " mfp-ie7"), r && b._addClassToMFP(r), b.updateItemHTML(), y("BuildControls"), a("html").css(n), b.bgOverlay.add(b.
132wrap).prependTo(b.st.prependTo || a(document.body)), b._lastFocusedEl = document.activeElement, setTimeout(function () { 133 b.content ? (b._addClassToMFP(q), b._setFocus()) : b.bgOverlay.addClass(q), d.on("focusin" + p, b._onFocusIn) 134 }, 16), b.isOpen = !0, b.updateSize(k), y(m), c 135 }, 136 close: function () { 137 add_theme_ga_tracking('æç« ', 'GalleryImageClickClose', post_title, '', 0); 138 add_themes_ga4_tracking('article_gallery_nav_click',{'item_type':'close_image_button'}); 139 b.isOpen && (y(i), b.isOpen = !1, b.st.removalDelay && !b.isLowIE && b.supportsTransition ? (b._addClassToMFP(r), setTimeout(function () { 140 // console.log('close'); 141 a('html').removeClass('noscroll'); 142 b._close() 143 }, b.st.removalDelay)) : b._close()) 144 }, 145 _close: function () { 146 y(h); 147 var c = r + " " + q + " "; 148 if (b.bgOverlay.detach(), b.wrap.detach(), b.container.empty(), b.st.mainClass && (c += b.st.mainClass + " "), b._removeClassFromMFP(c), b.fixedConteironos) { 149 var e = { 150 marginRight: "" 151 }; 152 // console.log('close'); 153 // a('html').removeClass('noscroll'); 154 b.isIE7 ? a("body, html").css("overflow", "") : e.overflow = "", a("html").css(e) 155 } 156 d.off("keyup" + p + " focusin" + p), b.ev.off(p), b.wrap.attr("class", "mfp-wrap").removeAttr("style"), b.bgOverlay.attr("class", "mfp-bg"), b.container.attr("class", "mfp-container"), !b.st.showCloseBtn || b.st.closeBtnInside && b.currTemplate[b.currItem.type] !== !0 || b.currTemplate.closeBtn && b.currTemplate.closeBtn.detach(), b.st.autoFocusLast && b._lastFocusedEl && a(b._lastFocusedEl).focus(), b.currItem = null, b.content = null, b.currTemplate = null, b.prevHeight = 0, y(j) 157 }, 158 updateSize: function (a) { 159 if (b.isIOS) { 160 var c = document.documentElement.clientWidth / window.innerWidth, 161 d = window.innerHeight * c; 162 b.wrap.css("height", d), b.wH = d 163 } else b.wH = a || v.height(); 164 b.fixedConteironos || b.wrap.css("height", b.wH), y("Resize") 165 }, 166 updateItemHTML: function () { 167 var c = b.items[b.index]; 168 b.contentContainer.detach(), b.content && b.content.detach(), c.parsed || (c = b.parseEl(b.index)); 169 var d = c.type; 170 if (y("BeforeChange", [b.currItem ? b.currItem.type : "", d]), b.currItem = c, !b.currTemplate[d]) { 171 var f = b.st[d] ? b.st[d].markup : !1; 172 y("FirstMarkupParse", f), f ? b.currTemplate[d] = a(f) : b.currTemplate[d] = !0 173 } 174 e && e !== c.type && b.container.removeClass("mfp-" + e + "-holder"); 175 var g = b["get" + d.charAt(0).toUpperCase() + d.slice(1)](c, b.currTemplate[d]); 176 b.appendContent(g, d), c.preloaded = !0, y(n, c), e = c.type, b.container.prepend(b.contentContainer), y("AfterChange") 177 }, 178 appendContent: function (a, c) { 179 b.content = a, a ? b.st.showCloseBtn && b.st.closeBtnInside && b.currTemplate[c] === !0 ? b.content.find(".mfp-close").length || b.content.append(z()) : b.content = a : b.content = "", y(k), b.container.addClass("mfp-" + c + "-holder"), b.contentContainer.append(b.content) 180 }, 181 parseEl: function (c) { 182 var d, e = b.items[c]; 183 if (e.tagName ? e = { 184 el: a(e) 185 } : (d = e.type, e = { 186 data: e, 187 src: e.src 188 }), e.el) { 189 for (var f = b.types, g = 0; g < f.length; g++) 190 if (e.el.hasClass("mfp-" + f[g])) { 191 d = f[g]; 192 break 193 } e.src = e.el.attr("data-mfp-src"), e.src || (e.src = e.el.attr("href")) 194 } 195 return e.type = d || b.st.type || "inline", e.index = c, e.parsed = !0, b.items[c] = e, y("Elemeironarse", e), b.items[c] 196 }, 197 addGroup: function (a, c) { 198 var d = function (d) { 199 d.mfpEl = this, b._openClick(d, a, c) 200 }; 201 c || (c = {}); 202 var e = "click.magnificPopup"; 203 c.mainEl = a, c.items ? (c.isObj = !0, a.off(e).on(e, d)) : (c.isObj = !1, c.delegate ? a.off(e).on(e, c.delegate, d) : (c.items = a, a.off(e).on(e, d))) 204 }, 205 _openClick: function (c, d, e) { 206 var f = void 0 !== e.midClick ? e.midClick : a.magnificPopup.defaults.midClick; 207 if (f || !(2 === c.which || c.ctrlKey || c.metaKey || c.altKey || c.shift
207Key)) { 208 var g = void 0 !== e.disableOn ? e.disableOn : a.magnificPopup.defaults.disableOn; 209 if (g) 210 if (a.isFunction(g)) { 211 if (!g.call(b)) return !0 212 } else if (v.width() < g) return !0; 213 c.type && (c.preventDefault(), b.isOpen && c.stopPropagation()), e.el = a(c.mfpEl), e.delegate && (e.items = d.find(e.delegate)), b.open(e) 214 } 215 }, 216 updateStatus: function (a, d) { 217 if (b.preloader) { 218 c !== a && b.container.removeClass("mfp-s-" + c), d || "loading" !== a || (d = b.st.tLoading); 219 var e = { 220 status: a, 221 text: d 222 }; 223 y("UpdateStatus", e), a = e.status, d = e.text, b.preloader.html(d), b.preloader.find("a").on("click", function (a) { 224 a.stopImmediatePropagation() 225 }), b.container.addClass("mfp-s-" + a), c = a 226 } 227 }, 228 _checkIfClose: function (c) { 229 if (!a(c).hasClass(s)) { 230 var d = b.st.closeOnContentClick, 231 e = b.st.closeOnBgClick; 232 if (d && e) return !0; 233 if (!b.content || a(c).hasClass("mfp-close") || b.preloader && c === b.preloader[0]) return !0; 234 if (c === b.content[0] || a.contains(b.content[0], c)) { 235 if (d) return !0 236 } else if (e && a.contains(document, c)) return !0; 237 return !1 238 } 239 }, 240 _addClassToMFP: function (a) { 241 b.bgOverlay.addClass(a), b.wrap.addClass(a) 242 }, 243 _removeClassFromMFP: function (a) { 244 this.bgOverlay.removeClass(a), b.wrap.removeClass(a) 245 }, 246 _hasScrollBar: function (a) { 247 return (b.isIE7 ? d.height() : document.body.scrollHeight) > (a || v.height()) 248 }, 249 _setFocus: function () { 250 (b.st.focus ? b.content.find(b.st.focus).eq(0) : b.wrap).focus() 251 }, 252 _onFocusIn: function (c) { 253 return c.target === b.wrap[0] || a.contains(b.wrap[0], c.target) ? void 0 : (b._setFocus(), !1) 254 }, 255 _parseMarkup: function (b, c, d) { 256 var e; 257 d.data && (c = a.extend(d.data, c)), y(l, [b, c, d]), a.each(c, function (c, d) { 258 if (void 0 === d || d === !1) return !0; 259 if (e = c.split("_"), e.length > 1) { 260 var f = b.find(p + "-" + e[0]); 261 if (f.length > 0) { 262 var g = e[1]; 263 "replaceWith" === g ? f[0] !== d[0] && f.replaceWith(d) : "img" === g ? f.is("img") ? f.attr("src", d) : f.replaceWith(a("<img>").attr("src", d).attr("class", f.attr("class"))) : f.attr(e[1], d) 264 } 265 } else b.find(p + "-" + c).html(d) 266 }) 267 }, 268 _getScrollbarSize: function () { 269 if (void 0 === b.scrollbarSize) { 270 var a = document.createElement("div"); 271 a.style.cssText = "width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;", document.body.appendChild(a), b.scrollbarSize = a.offsetWidth - a.clientWidth, document.body.removeChild(a) 272 } 273 return b.scrollbarSize 274 } 275 }, a.magnificPopup = { 276 instance: null, 277 proto: t.prototype, 278 modules: [], 279 open: function (b, c) { 280 return A(), b = b ? a.extend(!0, {}, b) : {}, b.isObj = !0, b.index = c || 0, this.instance.open(b) 281 }, 282 close: function () { 283 return a.magnificPopup.instance && a.magnificPopup.instance.close() 284 }, 285 registerModule: function (b, c) { 286 c.options && (a.magnificPopup.defaults[b] = c.options), a.extend(this.proto, c.proto), this.modules.push(b) 287 }, 288 defaults:{ 289 disableOn:0, 290 key:null, 291 midClick:!1, 292 mainClass:"", 293 preloader:!0, 294 focus:"", 295 closeOnContentClick:!1, 296 closeOnBgClick:!0, 297 closeBtnInside:!0, 298 showCloseBtn:!0, 299 enableEscapeKey:!0, 300 modal:!1, 301 alignTop:!1, 302 removalDelay:0, 303 prependTo:null, 304 fixedContentPos:true, 305 fixedBgPos:true, 306 overflowY:"auto", 307 closeMarkup:'<button title="%title%" type="button" class="mfp-close">×</button>', 308 tClose:"Close (Esc)", 309 tLoading:"Loading...", 310 autoFocusLast:!0 311 } 312 },a.fn.magnificPopup = function (c) { 313 A(); 314 var d = a(this); 315 if ("string" == typeof c) 316 if ("open" === c) { 317 var e, f = u ? d.data("magnificPopup") : d[0].magnificPopup, 318 g = parseInt(arguments[1], 10) || 0; 319 f.items ? e = f.items[g] : (e = d, f.delegate && (e = e.find(f.delegate)), e = e.eq(g)), b._openClick({ 320 mfpEl: e 321 }, d, f) 322 } else b.isOpen && b[c].apply(b, Array.prototype.slice.call(arguments, 1)); 323 else c = a.extend(!0, {}, c), u ? d.data("magnificPopup", c) : d[0].magnificPopup = c, b.addGroup(d, c); 324 return d 325 }; 326 var C, D, E, F = "inline", 327 G = function () { 328 E && (D.after(E.addClass(C)).detach(), E = null) 329 }; 330 a.magnificPopup.registerModule(F, { 331 options: { 332 hiddenClass: "hide", 333 markup: "", 334 tNotFound: "Content not found" 335 }, 336 proto: { 337 initInline: function () { 338 b.types.push(F), w(h + "." + F, function () { 339 G() 340 }) 341 }, 342 getInline: function (c, d) { 343 if (G(), c.src) { 344 var e = b.st.inline, 345 f = a(c.src); 346 if (f.length) { 347 var g = f[0].parentNode; 348 g && g.tagName && (D || (C = e.hiddenClass, D = x(C), C = "mfp-" + C), E = f.after(D).detach().removeClass(C)), b.updateStatus("ready") 349 } else b.updateStatus("error", e.tNotFound), f = a("<div>"); 350 return c.inlineElement = f, f 351 } 352 return b.updateStatus("ready"), b._parseMarkup(d, {}, c), d 353 } 354 } 355 }); 356 var H, I = "ajax", 357 J = function () { 358 H && a(document.body).removeClass(H) 359 }, 360 K = function () { 361 J(), b.req && b.req.abort() 362 }; 363 a.magnificPopup.registerModule(I, { 364 options: { 365 settings: null, 366 cursor: "mfp-ajax-cur", 367 tError: '<a href="%url%">The content</a> could not be loaded.' 368 }, 369 proto: { 370 initAjax: function () { 371 b.types.push(I), H = b.st.ajax.cursor, w(h + "." + I, K), w("BeforeChange." + I, K) 372 }, 373 getAjax: function (c) { 374 H && a(document.body).addClass(H), b.updateStatus("loading"); 375 var d = a.extend({ 376 url: c.src, 377 success: function (d, e, f) { 378 var g = { 379 data: d, 380 xhr: f 381 }; 382 y("ParseAjax", g), b.appendContent(a(g.data), I), c.finished = !0, J(), b._setFocus(), setTimeout(function () { 383 b.wrap.addClass(q) 384 }, 16), b.updateStatus("ready"), y("AjaxContentAdded") 385 }, 386 error: function () { 387 J(), c.finished = c.loadError = !0, b.updateStatus("error", b.st.ajax.tError.replace("%url%", c.src)) 388 } 389 }, b.st.ajax.settings); 390 return b.req = a.ajax(d), "" 391 } 392 } 393 }); 394 var L, M = function (c) { 395 if (c.data && void 0 !== c.data.title) return c.data.title;
396 var d = b.st.image.titleSrc; 397 // console.log("popup_title",b,c.data.title); 398 if (d) { 399 // var titleText=jQuery('.mfp-title'); 400 // console.log('.mfp-title.innerText:',titleText); 401 // b.container.append('<div class="mfp-bottom-bar"></div>'); 402 // jQuery(".mfp-title").more({length:10}); 403 if (a.isFunction(d)) return d.call(b, c); 404 if (c.el) return c.el.attr(d) || "" 405 } 406 return "" 407 }; 408 a.magnificPopup.registerModule("image", { 409 options: { 410 markup: '<div class="mfp-figure"><div class="mfp-topbar"><div class="mfp-counter"></div><div class="mfp-close"></div></div><figure><div class="mfp-img"></div></figure><figcaption><div class="mfp-bottom-bar"><div class="mfp-title-arrow up"><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 20 10"><defs><path id="__1muRZnB__a" d="M18.625.578a.565.565 0 01.75.844l-9 8a.565.565 0 01-.75 0l-9-8a.565.565 0 01.75-.844L10 8.244 18.625.578z"></path></defs><use transform="matrix(1 0 0 -1 0 10)" xlink:href="#__1muRZnB__a"></use></svg></div><div class="mfp-title"></div></div></figcaption></div>', 411 cursor: "mfp-zoom-out-cur", 412 titleSrc: "title", 413 verticalFit: !0, 414 tError: '<a href="%url%">The image</a> could not be loaded.' 415 }, 416 proto: { 417 initImage: function () { 418 var c = b.st.image, 419 d = ".image"; 420 b.types.push("image"), w(m + d, function () { 421 "image" === b.currItem.type && c.cursor && a(document.body).addClass(c.cursor) 422 }), w(h + d, function () { 423 c.cursor && a(document.body).removeClass(c.cursor), v.off("resize" + p) 424 }), w("Resize" + d, b.resizeImage), b.isLowIE && w("AfterChange", b.resizeImage) 425 }, 426 resizeImage: function () { 427 var a = b.currItem; 428 if (a && a.img && b.st.image.verticalFit) { 429 var c = 0; 430 var adHeight= 100; 431 // console.log("adHeight",b.wH - c - adHeight); 432 var gh=window.innerHeight; 433 b.isLowIE && (c = parseInt(a.img.css("padding-top"), 10) + parseInt(a.img.css("padding-bottom"), 10)), a.img.css("max-height", gh - 196) 434 // b.wH - c - adHeight - 103 435 } 436 }, 437 _onImageHasSize: function (a) { 438 a.img && (a.hasSize = !0, L && clearInterval(L), a.isCheckingImgSize = !1, y("ImageHasSize", a), a.imgHidden && (b.content && b.content.removeClass("mfp-loading"), a.imgHidden = !1)) 439 }, 440 findImageSize: function (a) { 441 var c = 0, 442 d = a.img[0], 443 e = function (f) { 444 L && clearInterval(L), L = setInterval(function () { 445 return d.naturalWidth > 0 ? void b._onImageHasSize(a) : (c > 200 && clearInterval(L), c++, void(3 === c ? e(10) : 40 === c ? e(50) : 100 === c && e(500))) 446 }, f) 447 }; 448 e(1) 449 }, 450 getImage: function (c, d) { 451 var e = 0, 452 f = function () { 453 c && (c.img[0].complete ? (c.img.off(".mfploader"), c === b.currItem && (b._onImageHasSize(c), b.updateStatus("ready")), c.hasSize = !0, c.loaded = !0, y("ImageLoadComplete")) : (e++, 200 > e ? setTimeout(f, 100) : g())) 454 }, 455 g = function () { 456 c && (c.img.off(".mfploader"), c === b.currItem && (b._onImageHasSize(c), b.updateStatus("error", h.tError.replace("%url%", c.src))), c.hasSize = !0, c.loaded = !0, c.loadError = !0) 457 }, 458 h = b.st.image, 459 i = d.find(".mfp-img"); 460 if (i.length) { 461 var j = document.createElement("img"); 462 j.className = "mfp-img", c.el && c.el.find("img").length && (j.alt = c.el.find("img").attr("alt")), c.img = a(j).on("load.mfploader", f).on("error.mfploader", g), j.src = c.src, i.is("img") && (c.img = c.img.clone()), j = c.img[0], j.naturalWi
462dth > 0 ? c.hasSize = !0 : j.width || (c.hasSize = !1) 463 } 464 return b._parseMarkup(d, { 465 title: M(c), 466 img_replaceWith: c.img 467 }, c), b.resizeImage(), c.hasSize ? (L && clearInterval(L), c.loadError ? (d.addClass("mfp-loading"), b.updateStatus("error", h.tError.replace("%url%", c.src))) : (d.removeClass("mfp-loading"), b.updateStatus("ready")), d) : (b.updateStatus("loading"), c.loading = !0, c.hasSize || (c.imgHidden = !0, d.addClass("mfp-loading"), b.findImageSize(c)), d) 468 } 469 } 470 }); 471 var N, O = function () { 472 return void 0 === N && (N = void 0 !== document.createElement("p").style.MozTransform), N 473 }; 474 a.magnificPopup.registerModule("zoom", { 475 options: { 476 enabled: !1, 477 easing: "ease-in-out", 478 duration: 300, 479 opener: function (a) { 480 return a.is("img") ? a : a.find("img") 481 } 482 }, 483 proto: { 484 initZoom: function () { 485 var a, c = b.st.zoom, 486 d = ".zoom"; 487 if (c.enabled && b.supportsTransition) { 488 var e, f, g = c.duration, 489 j = function (a) { 490 var b = a.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"), 491 d = "all " + c.duration / 1e3 + "s " + c.easing, 492 e = { 493 position: "fixed", 494 zIndex: 9999, 495 left: 0, 496 top: 0, 497 "-webkit-backface-visibility": "hidden" 498 }, 499 f = "transition"; 500 return e["-webkit-" + f] = e["-moz-" + f] = e["-o-" + f] = e[f] = d, b.css(e), b 501 }, 502 k = function () { 503 b.content.css("visibility", "visible") 504 }; 505 w("BuildControls" + d, function () { 506 if (b._allowZoom()) { 507 if (clearTimeout(e), b.content.css("visibility", "hidden"), a = b._getItemToZoom(), !a) return void k(); 508 f = j(a), f.css(b._getOffset()), b.wrap.append(f), e = setTimeout(function () { 509 f.css(b._getOffset(!0)), e = setTimeout(function () { 510 k(), setTimeout(function () { 511 f.remove(), a = f = null, y("ZoomAnimationEnded") 512 }, 16) 513 }, g) 514 }, 16) 515 } 516 }), w(i + d, function () { 517 if (b._allowZoom()) { 518 if (clearTimeout(e), b.st.removalDelay = g, !a) { 519 if (a = b._getItemToZoom(), !a) return; 520 f = j(a) 521 } 522 f.css(b._getOffset(!0)), b.wrap.append(f), b.content.css("visibility", "hidden"), setTimeout(function () { 523 f.css(b._getOffset()) 524 }, 16) 525 } 526 }), w(h + d, function () { 527 b._allowZoom() && (k(), f && f.remove(), a = null) 528 }) 529 } 530 }, 531 _allowZoom: function () { 532 return "image" === b.currItem.type 533 }, 534 _getItemToZoom: function () { 535 return b.currItem.hasSize ? b.currItem.img : !1 536 }, 537 _getOffset: function (c) { 538 var d; 539 d = c ? b.currItem.img : b.st.zoom.opener(b.currItem.el || b.currItem); 540 var e = d.offset(), 541 f = parseInt(d.css("padding-top"), 10), 542 g = parseInt(d.css("padding-bottom"), 10); 543 e.top -= a(window).scrollTop() - f; 544 var h = { 545 width: d.width(), 546 height: (u ? d.innerHeight() : d[0].offsetHeight) - g - f 547 }; 548 return O() ? h["-moz-transform"] = h.transform = "translate(" + e.left + "px," + e.top + "px)" : (h.left = e.left, h.top = e.top), h 549 } 550 } 551 }); 552 var P = "iframe", 553 Q = "//about:blank", 554 R = function (a) { 555 if (b.currTemplate[P]) { 556 var c = b.currTemplate[P].find("iframe"); 557 c.length && (a || (c[0].src = Q), b.isIE8 && c.css("display", a ? "block" : "none")) 558 } 559 }; 560 a.magnificPopup.registerModule(P, { 561 options: { 562 markup: '<div class="mfp-iframe-scaler"><div class="mfp-close"></div><iframe class="mfp-iframe" src="//about:blank" frameborder="0" allowfullscreen></iframe></div>', 563 srcAction: "iframe_src", 564 patterns: { 565 youtube: { 566 index: "youtube.com", 567 id: "v=", 568 src: "//www.youtube.com/embed/%id%?autoplay=1" 569 }, 570 vimeo: { 571 index: "vimeo.com/", 572 id: "/", 573 src: "//player.vimeo.com/video/%id%?autoplay=1" 574 }, 575 gmaps: { 576 index: "//maps.google.", 577 src: "%id%&output=embed" 578 } 579 } 580 }, 581 proto: { 582 initIframe: function () { 583 b.types.push(P), w("BeforeChange", function (a, b, c) { 584 b !== c && (b === P ? R() : c === P && R(!0)) 585 }), w(h + "." + P, function () { 586 R() 587 }) 588 }, 589 getIframe: function (c, d) { 590 var e = c.src, 591 f = b.st.iframe; 592 a.each(f.patterns, function () { 593 return e.indexOf(this.index) > -1 ? (this.id && (e = "string" == typeof this.id ? e.substr(e.lastIndexOf(this.id
593) + this.id.length, e.length) : this.id.call(this, e)), e = this.src.replace("%id%", e), !1) : void 0 594 }); 595 var g = {}; 596 return f.srcAction && (g[f.srcAction] = e), b._parseMarkup(d, g, c), b.updateStatus("ready"), d 597 } 598 } 599 }); 600 var S = function (a) { 601 var c = b.items.length; 602 return a > c - 1 ? a - c : 0 > a ? c + a : a 603 }, 604 T = function (a, b, c) { 605 return a.replace(/%curr%/gi, b + 1).replace(/%total%/gi, c) 606 }; 607 a.magnificPopup.registerModule("gallery", { 608 options: { 609 enabled: !1, 610 arrowMarkup: '<button title="%title%" type="button" class="mfp-arrow mfp-arrow-%dir%" wwwww></button>', 611 preload: [0, 2], 612 navigateByImgClick: !0, 613 arrows: !0, 614 tPrev: "Previous (Left arrow key)", 615 tNext: "Next (Right arrow key)", 616 tCounter: "%curr% of %total%" 617 }, 618 proto: { 619 initGallery: function () { 620 var c = b.st.gallery, 621 e = ".mfp-gallery"; 622 return b.direction = !0, c && c.enabled ? (f += " mfp-gallery", w(m + e, function () { 623 c.navigateByImgClick && b.wrap.on("click" + e, ".mfp-img", function () { 624 return b.items.length > 1 ? (b.next(), !1) : void 0 625 }), d.on("keydown" + e, function (a) { 626 37 === a.keyCode ? b.prev() : 39 === a.keyCode && b.next() 627 }) 628 }), w("UpdateStatus" + e, function (a, c) { 629 c.text && (c.text = T(c.text, b.currItem.index, b.items.length)) 630 }), w(l + e, function (a, d, e, f) { 631 var g = b.items.length; 632 e.counter = g > 1 ? T(c.tCounter, f.index, g) : "" 633 }), w("BuildControls" + e, function () { 634 if (b.items.length > 1 && c.arrows && !b.arrowLeft) { 635 var d = c.arrowMarkup, 636 e = b.arrowLeft = a(d.replace(/%title%/gi, c.tPrev).replace(/%dir%/gi, "left")).addClass(s), 637 f = b.arrowRight = a(d.replace(/%title%/gi, c.tNext).replace(/%dir%/gi, "right")).addClass(s); 638 // console.log('b.st:',b.st); 639 // var titleText=jQuery('.mfp-title')[0].innerText; 640 // console.log('.mfp-title:',titleText); 641 // b.container.append('<div class="mfp-bottom-bar">aaaaaaaaa</div>'); 642 e.click(function () { 643 b.prev() 644 }), f.click(function () { 645 b.next() 646 }), b.container.append(e.add(f)) 647 } 648 }), w(n + e, function () { 649 b._preloadTimeout && clearTimeout(b._preloadTimeout), b._preloadTimeout = setTimeout(function () { 650 b.preloadNearbyImages(), b._preloadTimeout = null 651 }, 16) 652 }), void w(h + e, function () { 653 d.off(e), b.wrap.off("click" + e), b.arrowRight = b.arrowLeft = null 654 })) : !1 655 }, 656 next: function () { 657 add_theme_ga_tracking('æç« ', 'GalleryImageClickRight', post_title, '', 0); 658 add_themes_ga4_tracking('article_gallery_nav_click',{'item_type':'next_image_button'}); 659 b.direction = !0, b.index = S(b.index + 1), b.updateItemHTML() 660 }, 661 prev: function () { 662 add_theme_ga_tracking('æç« ', 'GalleryImageClickLeft', post_title, '', 0); 663 add_themes_ga4_tracking('article_gallery_nav_click',{'item_type':'previous_image_button'}); 664 b.direction = !1, b.index = S(b.index - 1), b.updateItemHTML() 665 }, 666 goTo: function (a) { 667 b.direction = a >= b.index, b.index = a, b.updateItemHTML() 668 }, 669 preloadNearbyImages: function () { 670 var a, c = b.st.gallery.preload, 671 d = Math.min(c[0], b.items.length), 672 e = Math.min(c[1], b.items.length); 673 for (a = 1; a <= (b.direction ? e : d); a++) b._preloadItem(b.index + a); 674 for (a = 1; a <= (b.direction ? d : e); a++) b._preloadItem(b.index - a) 675 }, 676 _preloadItem: function (c) { 677 if (c = S(c), !b.items[c].preloaded) { 678 var d = b.items[c]; 679 d.parsed || (d = b.parseEl(c)), y("LazyLoad", d), "image" === d.t
679ype && (d.img = a('<img class="mfp-img" />').on("load.mfploader", function () { 680 d.hasSize = !0 681 }).on("error.mfploader", function () { 682 d.hasSize = !0, d.loadError = !0, y("LazyLoadError", d) 683 }).attr("src", d.src)), d.preloaded = !0 684 } 685 } 686 } 687 }); 688 var U = "retina"; 689 a.magnificPopup.registerModule(U, { 690 options: { 691 replaceSrc: function (a) { 692 return a.src.replace(/\.\w+$/, function (a) { 693 return "@2x" + a 694 }) 695 }, 696 ratio: 1 697 }, 698 proto: { 699 initRetina: function () { 700 if (window.devicePixelRatio > 1) { 701 var a = b.st.retina, 702 c = a.ratio; 703 c = isNaN(c) ? c() : c, c > 1 && (w("ImageHasSize." + U, function (a, b) { 704 b.img.css({ 705 "max-width": b.img[0].naturalWidth / c, 706 width: "100%" 707 }) 708 }), w("Elemeironarse." + U, function (b, d) { 709 d.src = a.replaceSrc(d, c) 710 })) 711 } 712 } 713 } 714 }), A() 715});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.