1var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {}; 2function getDefaultExportFromCjs(x) { 3 return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x; 4} 5var glightbox_min = { exports: {} }; 6(function(module, exports) { 7 !function(e, t) { 8 module.exports = t(); 9 }(commonjsGlobal, function() { 10 function e(e2, t2) { 11 if (!(e2 instanceof t2)) 12 throw new TypeError("Cannot call a class as a function"); 13 } 14 function t(e2, t2) { 15 for (var i2 = 0; i2 < t2.length; i2++) { 16 var s2 = t2[i2]; 17 s2.enumerable = s2.enumerable || false, s2.configurable = true, "value" in s2 && (s2.writable = true), Object.defineProperty(e2, n(s2.key), s2); 18 } 19 } 20 function i(e2, i2, n2) { 21 return i2 && t(e2.prototype, i2), Object.defineProperty(e2, "prototype", { writable: false }), e2; 22 } 23 function n(e2) { 24 var t2 = function(e3, t3) { 25 if ("object" != typeof e3 || !e3) 26 return e3; 27 var i2 = e3[Symbol.toPrimitive]; 28 if (void 0 !== i2) { 29 var n2 = i2.call(e3, t3); 30 if ("object" != typeof n2) 31 return n2; 32 throw new TypeError("@@toPrimitive must return a primitive value."); 33 } 34 return String(e3); 35 }(e2, "string"); 36 return "symbol" == typeof t2 ? t2 : t2 + ""; 37 } 38 function s(e2) { 39 return (s = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e3) { 40 return typeof e3; 41 } : function(e3) { 42 return e3 && "function" == typeof Symbol && e3.constructor === Symbol && e3 !== Symbol.prototype ? "symbol" : typeof e3; 43 })(e2); 44 } 45 var l = Date.now(); 46 function o() { 47 var e2 = {}, t2 = true, i2 = 0, n2 = arguments.length; 48 "[object Boolean]" === Object.prototype.toString.call(arguments[0]) && (t2 = arguments[0], i2++); 49 for (var s2 = function(i3) { 50 for (var n3 in i3) 51 Object.prototype.hasOwnProperty.call(i3, n3) && (t2 && "[object Object]" === Object.prototype.toString.call(i3[n3]) ? e2[n3] = o(true, e2[n3], i3[n3]) : e2[n3] = i3[n3]); 52 }; i2 < n2; i2++) { 53 var l2 = arguments[i2]; 54 s2(l2); 55 } 56 return e2; 57 } 58 function r(e2, t2) { 59 if ((E(e2) || e2 === window || e2 === document) && (e2 = [e2]), L(e2) || I(e2) || (e2 = [e2]), 0 != M(e2)) { 60 if (L(e2) && !I(e2)) 61 for (var i2 = e2.length, n2 = 0; n2 < i2 && false !== t2.call(e2[n2], e2[n2], n2, e2); n2++) 62 ; 63 else if (I(e2)) { 64 for (var s2 in e2) 65 if (P(e2, s2) && false === t2.call(e2[s2], e2[s2], s2, e2)) 66 break; 67 } 68 } 69 } 70 function a(e2) { 71 var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : null, i2 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : null, n2 = e2[l] = e2[l] || [], s2 = { all: n2, evt: null, found: null }; 72 return t2 && i2 && M(n2) > 0 && r(n2, function(e3, n3) { 73 if (e3.eventName == t2 && e3.fn.toString() == i2.toString()) 74 return s2.found = true, s2.evt = n3, false; 75 }), s2; 76 } 77 function h(e2) { 78 var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}, i2 = t2.onElement, n2 = t2.withCallback, s2 = t2.avoidDuplicate, l2 = void 0 === s2 || s2, o2 = t2.once, h2 = void 0 !== o2 && o2, d2 = t2.useCapture, c2 = void 0 !== d2 && d2, u2 = arguments.length > 2 ? arguments[2] : void 0, g2 = i2 || []; 79 function v2(e3) { 80 C(n2) && n2.call(u2, e3, this), h2 && v2.destroy(); 81 } 82 return k(g2) && (g2 = document.querySelectorAll(g2)), v2.destroy = function() { 83 r(g2, function(t3) { 84 var i3 = a(t3, e2, v2); 85 i3.found && i3.all.splice(i3.evt, 1), t3.removeEventListener && t3.removeEventListener(e2, v2, c2); 86 }); 87 }, r(g2, function(t3) { 88 var i3 = a(t3, e2, v2); 89 (t3.addEventListener && l2 && !i3.found || !l2) && (t3.addEventListener(e2, v2, c2), i3.all.push({ eventName: e2, fn: v2 })); 90 }), v2; 91 } 92 function d(e2, t2) { 93 r(t2.split(" "), function(t3) { 94 return e2.classList.add(t3); 95 }); 96 } 97 function c(e2, t2) { 98 r(t2.split(" "), function(t3) { 99 return e2.classList.remove(t3); 100 }); 101 } 102 function u(e2, t2) { 103 return e2.classList.contains(t2); 104 } 105 function g(e2, t2) { 106 for (; e2 !== document.body; ) { 107 if (!(e2 = e2.parentElement)) 108 return false;
109 if ("function" == typeof e2.matches ? e2.matches(t2) : e2.msMatchesSelector(t2)) 110 return e2; 111 } 112 } 113 function v(e2) { 114 var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "", i2 = arguments.length > 2 && void 0 !== arguments[2] && arguments[2]; 115 if (!e2 || "" === t2) 116 return false; 117 if ("none" === t2) 118 return C(i2) && i2(), false; 119 var n2 = b(), s2 = t2.split(" "); 120 r(s2, function(t3) { 121 d(e2, "g" + t3); 122 }), h(n2, { onElement: e2, avoidDuplicate: false, once: true, withCallback: function(e3, t3) { 123 r(s2, function(e4) { 124 c(t3, "g" + e4); 125 }), C(i2) && i2(); 126 } }); 127 } 128 function f(e2) { 129 var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : ""; 130 if ("" === t2) 131 return e2.style.webkitTransform = "", e2.style.MozTransform = "", e2.style.msTransform = "", e2.style.OTransform = "", e2.style.transform = "", false; 132 e2.style.webkitTransform = t2, e2.style.MozTransform = t2, e2.style.msTransform = t2, e2.style.OTransform = t2, e2.style.transform = t2; 133 } 134 function p(e2) { 135 e2.style.display = "block"; 136 } 137 function m(e2) { 138 e2.style.display = "none"; 139 } 140 function y(e2) { 141 var t2 = document.createDocumentFragment(), i2 = document.createElement("div"); 142 for (i2.innerHTML = e2; i2.firstChild; ) 143 t2.appendChild(i2.firstChild); 144 return t2; 145 } 146 function x() { 147 return { width: window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth, height: window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight }; 148 } 149 function b() { 150 var e2, t2 = document.createElement("fakeelement"), i2 = { animation: "animationend", OAnimation: "oAnimationEnd", MozAnimation: "animationend", WebkitAnimation: "webkitAnimationEnd" }; 151 for (e2 in i2) 152 if (void 0 !== t2.style[e2]) 153 return i2[e2]; 154 } 155 function S(e2, t2, i2, n2) { 156 if (e2()) 157 t2(); 158 else { 159 var s2; 160 i2 || (i2 = 100); 161 var l2 = setInterval(function() { 162 e2() && (clearInterval(l2), s2 && clearTimeout(s2), t2()); 163 }, i2); 164 } 165 } 166 function w(e2, t2, i2) { 167 if (O(e2)) 168 console.error("Inject assets error"); 169 else if (C(t2) && (i2 = t2, t2 = false), k(t2) && t2 in window) 170 C(i2) && i2(); 171 else { 172 var n2; 173 if (-1 !== e2.indexOf(".css")) { 174 if ((n2 = document.querySelectorAll('link[href="' + e2 + '"]')) && n2.length > 0) 175 return void (C(i2) && i2()); 176 var s2 = document.getElementsByTagName("head")[0], l2 = s2.querySelectorAll('link[rel="stylesheet"]'), o2 = document.createElement("link"); 177 return o2.rel = "stylesheet", o2.type = "text/css", o2.href = e2, o2.media = "all", l2 ? s2.insertBefore(o2, l2[0]) : s2.appendChild(o2), void (C(i2) && i2()); 178 } 179 if ((n2 = document.querySelectorAll('script[src="' + e2 + '"]')) && n2.length > 0) { 180 if (C(i2)) { 181 if (k(t2)) 182 return S(function() { 183 return void 0 !== window[t2]; 184 }, function() { 185 i2(); 186 }), false; 187 i2(); 188 } 189 } else { 190 var r2 = document.createElement("script"); 191 r2.type = "text/javascript", r2.src = e2, r2.onload = function() { 192 if (C(i2)) { 193 if (k(t2)) 194 return S(function() { 195 return void 0 !== window[t2]; 196 }, function() { 197 i2(); 198 }), false; 199 i2(); 200 } 201 }, document.body.appendChild(r2); 202 } 203 } 204 } 205 function T() { 206 return "navigator" in window && window.navigator.userAgent.match(/(iPad)|(iPhone)|(iPod)|(Android)|(PlayBook)|(BB10)|(BlackBerry)|(Opera Mini)|(IEMobile)|(webOS)|(MeeGo)/i); 207 } 208 function C(e2) { 209 return "function" == typeof e2; 210 } 211 function k(e2) { 212 return "string" == typeof e2; 213 } 214 function E(e2) { 215 return !(!e2 || !e2.nodeType || 1 != e2.nodeType); 216 } 217 function A(e2) { 218 return Array.isArray(e2); 219 } 220 function L(e2) { 221 return e2 && e2.length && isFinite(e2.length); 222 } 223 function I(e2) { 224 return "object" === s(e2) && null != e2 && !C(e2) && !A(e2); 225 } 226 function O(e2) { 227 return null == e2; 228 } 229 function P(e2, t2) { 230 return null !== e2 && hasOwnProperty.call(e2, t2); 231 } 232 function M(e2) { 233 if (I(e2)) {
234 if (e2.keys) 235 return e2.keys().length; 236 var t2 = 0; 237 for (var i2 in e2) 238 P(e2, i2) && t2++; 239 return t2; 240 } 241 return e2.length; 242 } 243 function z(e2) { 244 return !isNaN(parseFloat(e2)) && isFinite(e2); 245 } 246 function X() { 247 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : -1, t2 = document.querySelectorAll(".gbtn[data-taborder]:not(.disabled)"); 248 if (!t2.length) 249 return false; 250 if (1 == t2.length) 251 return t2[0]; 252 "string" == typeof e2 && (e2 = parseInt(e2)); 253 var i2 = []; 254 r(t2, function(e3) { 255 i2.push(e3.getAttribute("data-taborder")); 256 }); 257 var n2 = Math.max.apply(Math, i2.map(function(e3) { 258 return parseInt(e3); 259 })), s2 = e2 < 0 ? 1 : e2 + 1; 260 s2 > n2 && (s2 = "1"); 261 var l2 = i2.filter(function(e3) { 262 return e3 >= parseInt(s2); 263 }), o2 = l2.sort()[0]; 264 return document.querySelector('.gbtn[data-taborder="'.concat(o2, '"]')); 265 } 266 function Y(e2) { 267 if (e2.events.hasOwnProperty("keyboard")) 268 return false; 269 e2.events.keyboard = h("keydown", { onElement: window, withCallback: function(t2, i2) { 270 var n2 = (t2 = t2 || window.event).keyCode; 271 if (9 == n2) { 272 var s2 = document.querySelector(".gbtn.focused"); 273 if (!s2) { 274 var l2 = !(!document.activeElement || !document.activeElement.nodeName) && document.activeElement.nodeName.toLocaleLowerCase(); 275 if ("input" == l2 || "textarea" == l2 || "button" == l2) 276 return; 277 } 278 t2.preventDefault(); 279 var o2 = document.querySelectorAll(".gbtn[data-taborder]"); 280 if (!o2 || o2.length <= 0) 281 return; 282 if (!s2) { 283 var r2 = X(); 284 return void (r2 && (r2.focus(), d(r2, "focused"))); 285 } 286 var a2 = X(s2.getAttribute("data-taborder")); 287 c(s2, "focused"), a2 && (a2.focus(), d(a2, "focused")); 288 } 289 39 == n2 && e2.nextSlide(), 37 == n2 && e2.prevSlide(), 27 == n2 && e2.close(); 290 } }); 291 } 292 var q = i(function t2(i2, n2) { 293 var s2 = this, l2 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : null; 294 if (e(this, t2), this.img = i2, this.slide = n2, this.onclose = l2, this.img.setZoomEvents) 295 return false; 296 this.active = false, this.zoomedIn = false, this.dragging = false, this.currentX = null, this.currentY = null, this.initialX = null, this.initialY = null, this.xOffset = 0, this.yOffset = 0, this.img.addEventListener("mousedown", function(e2) { 297 return s2.dragStart(e2); 298 }, false), this.img.addEventListener("mouseup", function(e2) { 299 return s2.dragEnd(e2); 300 }, false), this.img.addEventListener("mousemove", function(e2) { 301 return s2.drag(e2); 302 }, false), this.img.addEventListener("click", function(e2) { 303 return s2.slide.classList.contains("dragging-nav") ? (s2.zoomOut(), false) : s2.zoomedIn ? void (s2.zoomedIn && !s2.dragging && s2.zoomOut()) : s2.zoomIn(); 304 }, false), this.img.setZoomEvents = true; 305 }, [{ key: "zoomIn", value: function() { 306 var e2 = this.widowWidth(); 307 if (!(this.zoomedIn || e2 <= 768)) { 308 var t2 = this.img; 309 if (t2.setAttribute("data-style", t2.getAttribute("style")), t2.style.maxWidth = t2.naturalWidth + "px", t2.style.maxHeight = t2.naturalHeight + "px", t2.naturalWidth > e2) { 310 var i2 = e2 / 2 - t2.naturalWidth / 2; 311 this.setTranslate(this.img.parentNode, i2, 0); 312 } 313 this.slide.classList.add("zoomed"), this.zoomedIn = true; 314 } 315 } }, { key: "zoomOut", value: function() { 316 this.img.parentNode.setAttribute("style", ""), this.img.setAttribute("style", this.img.getAttribute("data-style")), this.slide.classList.remove("zoomed"), this.zoomedIn = false, this.currentX = null, this.currentY = null, this.initialX = null, this.initialY = null, this.xOffset = 0, this.yOffset = 0, this.onclose && "function" == typeof this.onclose && this.onclose(); 317 } }, { key: "dragStart", value: function(e2) { 318 e2.preventDefault(), this.zoomedIn ? ("touchstart" === e2.type ? (this.initialX = e2.touches[0].clientX - this.xOffset, this.initialY = e2.touches[0].clientY - this.yOffset)
318: (this.initialX = e2.clientX - this.xOffset, this.initialY = e2.clientY - this.yOffset), e2.target === this.img && (this.active = true, this.img.classList.add("dragging"))) : this.active = false; 319 } }, { key: "dragEnd", value: function(e2) { 320 var t2 = this; 321 e2.preventDefault(), this.initialX = this.currentX, this.initialY = this.currentY, this.active = false, setTimeout(function() { 322 t2.dragging = false, t2.img.isDragging = false, t2.img.classList.remove("dragging"); 323 }, 100); 324 } }, { key: "drag", value: function(e2) { 325 this.active && (e2.preventDefault(), "touchmove" === e2.type ? (this.currentX = e2.touches[0].clientX - this.initialX, this.currentY = e2.touches[0].clientY - this.initialY) : (this.currentX = e2.clientX - this.initialX, this.currentY = e2.clientY - this.initialY), this.xOffset = this.currentX, this.yOffset = this.currentY, this.img.isDragging = true, this.dragging = true, this.setTranslate(this.img, this.currentX, this.currentY)); 326 } }, { key: "onMove", value: function(e2) { 327 if (this.zoomedIn) { 328 var t2 = e2.clientX - this.img.naturalWidth / 2, i2 = e2.clientY - this.img.naturalHeight / 2; 329 this.setTranslate(this.img, t2, i2); 330 } 331 } }, { key: "setTranslate", value: function(e2, t2, i2) { 332 e2.style.transform = "translate3d(" + t2 + "px, " + i2 + "px, 0)"; 333 } }, { key: "widowWidth", value: function() { 334 return window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; 335 } }]), N = i(function t2() { 336 var i2 = this, n2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}; 337 e(this, t2); 338 var s2 = n2.dragEl, l2 = n2.toleranceX, o2 = void 0 === l2 ? 40 : l2, r2 = n2.toleranceY, a2 = void 0 === r2 ? 65 : r2, h2 = n2.slide, d2 = void 0 === h2 ? null : h2, c2 = n2.instance, u2 = void 0 === c2 ? null : c2; 339 this.el = s2, this.active = false, this.dragging = false, this.currentX = null, this.currentY = null, this.initialX = null, this.initialY = null, this.xOffset = 0, this.yOffset = 0, this.direction = null, this.lastDirection = null, this.toleranceX = o2, this.toleranceY = a2, this.toleranceReached = false, this.dragContainer = this.el, this.slide = d2, this.instance = u2, this.el.addEventListener("mousedown", function(e2) { 340 return i2.dragStart(e2); 341 }, false), this.el.addEventListener("mouseup", function(e2) { 342 return i2.dragEnd(e2); 343 }, false), this.el.addEventListener("mousemove", function(e2) { 344 return i2.drag(e2); 345 }, false); 346 }, [{ key: "dragStart", value: function(e2) { 347 if (this.slide.classList.contains("zoomed")) 348 this.active = false; 349 else { 350 "touchstart" === e2.type ? (this.initialX = e2.touches[0].clientX - this.xOffset, this.initialY = e2.touches[0].clientY - this.yOffset)
350: (this.initialX = e2.clientX - this.xOffset, this.initialY = e2.clientY - this.yOffset); 351 var t2 = e2.target.nodeName.toLowerCase(); 352 e2.target.classList.contains("nodrag") || g(e2.target, ".nodrag") || -1 !== ["input", "select", "textarea", "button", "a"].indexOf(t2) ? this.active = false : (e2.preventDefault(), (e2.target === this.el || "img" !== t2 && g(e2.target, ".gslide-inline")) && (this.active = true, this.el.classList.add("dragging"), this.dragContainer = g(e2.target, ".ginner-container"))); 353 } 354 } }, { key: "dragEnd", value: function(e2) { 355 var t2 = this; 356 e2 && e2.preventDefault(), this.initialX = 0, this.initialY = 0, this.currentX = null, this.currentY = null, this.initialX = null, this.initialY = null, this.xOffset = 0, this.yOffset = 0, this.active = false, this.doSlideChange && (this.instance.preventOutsideClick = true, "right" == this.doSlideChange && this.instance.prevSlide(), "left" == this.doSlideChange && this.instance.nextSlide()), this.doSlideClose && this.instance.close(), this.toleranceReached || this.setTranslate(this.dragContainer, 0, 0, true), setTimeout(function() { 357 t2.instance.preventOutsideClick = false, t2.toleranceReached = false, t2.lastDirection = null, t2.dragging = false, t2.el.isDragging = false, t2.el.classList.remove("dragging"), t2.slide.classList.remove("dragging-nav"), t2.dragContainer.style.transform = "", t2.dragContainer.style.transition = ""; 358 }, 100); 359 } }, { key: "drag", value: function(e2) { 360 if (this.active) { 361 e2.preventDefault(), this.slide.classList.add("dragging-nav"), "touchmove" === e2.type ? (this.currentX = e2.touches[0].clientX - this.initialX, this.currentY = e2.touches[0].clientY - this.initialY) : (this.currentX = e2.clientX - this.initialX, this.currentY = e2.clientY - this.initialY), this.xOffset = this.currentX, this.yOffset = this.currentY, this.el.isDragging = true, this.dragging = true, this.doSlideChange = false, this.doSlideClose = false; 362 var t2 = Math.abs(this.currentX), i2 = Math.abs(this.currentY); 363 if (t2 > 0 && t2 >= Math.abs(this.currentY) && (!this.lastDirection || "x" == this.lastDirection)) { 364 this.yOffset = 0, this.lastDirection = "x", this.setTranslate(this.dragContainer, this.currentX, 0); 365 var n2 = this.shouldChange(); 366 if (!this.instance.settings.dragAutoSnap && n2 && (this.doSlideChange = n2), this.instance.settings.dragAutoSnap && n2) 367 return this.instance.preventOutsideClick = true, this.toleranceReached = true, this.active = false, this.instance.preventOutsideClick = true, this.dragEnd(null), "right" == n2 && this.instance.prevSlide(), void ("left" == n2 && this.instance.nextSlide()); 368 } 369 if (this.toleranceY > 0 && i2 > 0 && i2 >= t2 && (!this.lastDirection || "y" == this.lastDirection)) { 370 this.xOffset = 0, this.lastDirection = "y", this.setTranslate(this.dragContainer, 0, this.currentY); 371 var s2 = this.shouldClose(); 372 return !this.instance.settings.dragAutoSnap && s2 && (this.doSlideClose = true), void (this.instance.settings.dragAutoSnap && s2 && this.instance.close()); 373 } 374 } 375 } }, { key: "shouldChange", value: function() { 376 var e2 = false; 377 if (Math.abs(this.currentX) >= this.toleranceX) { 378 var t2 = this.currentX > 0 ? "right" : "left"; 379 ("left" == t2 && this.slide !== this.slide.parentNode.lastChild || "right" == t2 && this.slide !== this.slide.parentNode.firstChild) && (e2 = t2); 380 } 381 return e2; 382 } }, { key: "shouldClose", value: function() { 383 var e2 = false; 384 return Math.abs(this.currentY) >= this.toleranceY && (e2 = true), e2; 385 } }, { key: "setTranslate", value: function(e2, t2, i2) { 386 var n2 = arguments.length > 3 && void 0 !== arguments[3] && arguments[3]; 387 e2.style.transition = n2 ? "all .2s ease" : "", e2.style.transform = "translate3d(".concat(t2, "px, ").concat(i2, "px, 0)"); 388 } }]); 389 function D(e2, t2, i2, n2) { 390 var s2 = e2.querySelector(".gslide-media"), l2 = new Image(), o2 = "gSlideTitle_" + i2, r2 = "gSlideDesc_" + i2; 391 l2.addEventListener("load", function() { 392 C(n2) && n2(); 393 }, false), l2.src = t2.href, "" != t2.sizes && "" != t2.srcset && (l2.sizes = t2.sizes, l2.srcset = t2.srcset), l2.alt = "", O(t2.alt) || "" === t2.alt || (l2.alt = t2.alt), "" !== t2.title && l2.setAttribute("aria-labelledby", o2), ""
393!== t2.description && l2.setAttribute("aria-describedby", r2), t2.hasOwnProperty("_hasCustomWidth") && t2._hasCustomWidth && (l2.style.width = t2.width), t2.hasOwnProperty("_hasCustomHeight") && t2._hasCustomHeight && (l2.style.height = t2.height), s2.insertBefore(l2, s2.firstChild); 394 } 395 function _(e2, t2, i2, n2) { 396 var s2 = this, l2 = e2.querySelector(".ginner-container"), o2 = "gvideo" + i2, r2 = e2.querySelector(".gslide-media"), a2 = this.getAllPlayers(); 397 d(l2, "gvideo-container"), r2.insertBefore(y('<div class="gvideo-wrapper"></div>'), r2.firstChild); 398 var h2 = e2.querySelector(".gvideo-wrapper"); 399 w(this.settings.plyr.css, "Plyr"); 400 var c2 = t2.href, u2 = null == t2 ? void 0 : t2.videoProvider, g2 = false; 401 r2.style.maxWidth = t2.width, w(this.settings.plyr.js, "Plyr", function() { 402 if (!u2 && c2.match(/vimeo\.com\/([0-9]*)/) && (u2 = "vimeo"), !u2 && (c2.match(/(youtube\.com|youtube-nocookie\.com)\/watch\?v=([a-zA-Z0-9\-_]+)/) || c2.match(/youtu\.be\/([a-zA-Z0-9\-_]+)/) || c2.match(/(youtube\.com|youtube-nocookie\.com)\/embed\/([a-zA-Z0-9\-_]+)/) || c2.match(/(youtube\.com|youtube-nocookie\.com)\/shorts\/([a-zA-Z0-9\-_]+)/)) && (u2 = "youtube"), "local" === u2 || !u2) { 403 u2 = "local"; 404 var l3 = '<video id="' + o2 + '" '; 405 l3 += 'style="background:#000; max-width: '.concat(t2.width, ';" '), l3 += 'preload="metadata" ', l3 += 'x-webkit-airplay="allow" ', l3 += "playsinline ", l3 += "controls ", l3 += 'class="gvideo-local">', l3 += '<source src="'.concat(c2, '">'), g2 = y(l3 += "</video>"); 406 } 407 var r3 = g2 || y('<div id="'.concat(o2, '" data-plyr-provider="').concat(u2, '" data-plyr-embed-id="').concat(c2, '"></div>')); 408 d(h2, "".concat(u2, "-video gvideo")), h2.appendChild(r3), h2.setAttribute("data-id", o2), h2.setAttribute("data-index", i2); 409 var v2 = P(s2.settings.plyr, "config") ? s2.settings.plyr.config : {}, f2 = new Plyr("#" + o2, v2); 410 f2.on("ready", function(e3) { 411 a2[o2] = e3.detail.plyr, C(n2) && n2(); 412 }), S(function() { 413 return e2.querySelector("iframe") && "true" == e2.querySelector("iframe").dataset.ready; 414 }, function() { 415 s2.resize(e2); 416 }), f2.on("enterfullscreen", W), f2.on("exitfullscreen", W); 417 }); 418 } 419 function W(e2) { 420 var t2 = g(e2.target, ".gslide-media"); 421 "enterfullscreen" === e2.type && d(t2, "fullscreen"), "exitfullscreen" === e2.type && c(t2, "fullscreen"); 422 } 423 function B(e2, t2, i2, n2) { 424 var s2, l2 = this, o2 = e2.querySelector(".gslide-media"), r2 = !(!P(t2, "href") || !t2.href) && t2.href.split("#").pop().trim(), a2 = !(!P(t2, "content") || !t2.content) && t2.content; 425 if (a2 && (k(a2) && (s2 = y('<div class="ginlined-content">'.concat(a2, "</div>"))), E(a2))) { 426 "none" == a2.style.display && (a2.style.display = "block"); 427 var c2 = document.createElement("div"); 428 c2.className = "ginlined-content", c2.appendChild(a2), s2 = c2; 429 } 430 if (r2) { 431 var u2 = document.getElementById(r2); 432 if (!u2) 433 return false; 434 var g2 = u2.cloneNode(true); 435 g2.style.height = t2.height, g2.style.maxWidth = t2.width, d(g2, "ginlined-content"), s2 = g2; 436 } 437 if (!s2) 438 return console.error("Unable to append inline slide content", t2), false; 439 o2.style.height = t2.height, o2.style.width = t2.width, o2.appendChild(s2), this.events["inlineclose" + r2] = h("click", { onElement: o2.querySelectorAll(".gtrigger-close"), withCallback: function(e3) { 440 e3.preventDefault(), l2.close(); 441 } }), C(n2) && n2(); 442 } 443 function H(e2, t2, i2, n2) { 444 var s2 = e2.querySelector(".gslide-media"), l2 = function(e3) { 445 var t3 = e3.url, i3 = e3.allow, n3 = e3.callback, s3 = e3.appendTo, l3 = document.createElement("iframe"); 446 return l3.className = "vimeo-video gvideo", l3.src = t3, l3.style.width = "100%", l3.style.height = "100%", i3 && l3.setAttribute("allow", i3), l3.onload = function() { 447 l3.onload = null, d(l3, "node-ready"), C(n3) && n3(); 448 }, s3 && s3.appendChild(l3), l3; 449 }({ url: t2.href, callback: n2 }); 450 s2.parentNode.style.maxWidth = t2.width, s2.parentNode.style.height = t2.he
450ight, s2.appendChild(l2); 451 } 452 var j = i(function t2() { 453 var i2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}; 454 e(this, t2), this.defaults = { href: "", sizes: "", srcset: "", title: "", type: "", videoProvider: "", description: "", alt: "", descPosition: "bottom", effect: "", width: "", height: "", content: false, zoomable: true, draggable: true }, I(i2) && (this.defaults = o(this.defaults, i2)); 455 }, [{ key: "sourceType", value: function(e2) { 456 var t2 = e2; 457 return null !== (e2 = e2.toLowerCase()).match(/\.(jpeg|jpg|jpe|gif|png|apn|webp|avif|svg)/) ? "image" : e2.match(/(youtube\.com|youtube-nocookie\.com)\/watch\?v=([a-zA-Z0-9\-_]+)/) || e2.match(/youtu\.be\/([a-zA-Z0-9\-_]+)/) || e2.match(/(youtube\.com|youtube-nocookie\.com)\/embed\/([a-zA-Z0-9\-_]+)/) || e2.match(/(youtube\.com|youtube-nocookie\.com)\/shorts\/([a-zA-Z0-9\-_]+)/) || e2.match(/vimeo\.com\/([0-9]*)/) || null !== e2.match(/\.(mp4|ogg|webm|mov)/) ? "video" : null !== e2.match(/\.(mp3|wav|wma|aac|ogg)/) ? "audio" : e2.indexOf("#") > -1 && "" !== t2.split("#").pop().trim() ? "inline" : e2.indexOf("goajax=true") > -1 ? "ajax" : "external"; 458 } }, { key: "parseConfig", value: function(e2, t2) { 459 var i2 = this, n2 = o({ descPosition: t2.descPosition }, this.defaults); 460 if (I(e2) && !E(e2)) { 461 P(e2, "type") || (P(e2, "content") && e2.content ? e2.type = "inline" : P(e2, "href") && (e2.type = this.sourceType(e2.href))); 462 var s2 = o(n2, e2); 463 return this.setSize(s2, t2), s2; 464 } 465 var l2 = "", a2 = e2.getAttribute("data-glightbox"), h2 = e2.nodeName.toLowerCase(); 466 if ("a" === h2 && (l2 = e2.href), "img" === h2 && (l2 = e2.src, n2.alt = e2.alt), n2.href = l2, r(n2, function(s3, l3) { 467 P(t2, l3) && "width" !== l3 && (n2[l3] = t2[l3]); 468 var o2 = e2.dataset[l3]; 469 O(o2) || (n2[l3] = i2.sanitizeValue(o2)); 470 }), n2.content && (n2.type = "inline"), !n2.type && l2 && (n2.type = this.sourceType(l2)), O(a2)) { 471 if (!n2.title && "a" == h2) { 472 var d2 = e2.title; 473 O(d2) || "" === d2 || (n2.title = d2); 474 } 475 if (!n2.title && "img" == h2) { 476 var c2 = e2.alt; 477 O(c2) || "" === c2 || (n2.title = c2); 478 } 479 } else { 480 var u2 = []; 481 r(n2, function(e3, t3) { 482 u2.push(";\\s?" + t3); 483 }), u2 = u2.join("\\s?:|"), "" !== a2.trim() && r(n2, function(e3, t3) { 484 var s3 = a2, l3 = new RegExp("s?" + t3 + "s?:s?(.*?)(" + u2 + "s?:|$)"), o2 = s3.match(l3); 485 if (o2 && o2.length && o2[1]) { 486 var r2 = o2[1].trim().replace(/;\s*$/, ""); 487 n2[t3] = i2.sanitizeValue(r2); 488 } 489 }); 490 } 491 if (n2.description && "." === n2.description.substring(0, 1)) { 492 var g2; 493 try { 494 g2 = document.querySelector(n2.description).innerHTML; 495 } catch (e3) { 496 if (!(e3 instanceof DOMException)) 497 throw e3; 498 } 499 g2 && (n2.description = g2); 500 } 501 if (!n2.description) { 502 var v2 = e2.querySelector(".glightbox-desc"); 503 v2 && (n2.description = v2.innerHTML); 504 } 505 return this.setSize(n2, t2, e2), this.slideConfig = n2, n2; 506 } }, { key: "setSize", value: function(e2, t2) { 507 var i2 = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : null, n2 = "video" == e2.type ? this.checkSize(t2.videosWidth) : this.checkSize(t2.width), s2 = this.checkSize(t2.height); 508 return e2.width = P(e2, "width") && "" !== e2.width ? this.checkSize(e2.width) : n2, e2.height = P(e2, "height") && "" !== e2.height ? this.checkSize(e2.height) : s2, i2 && "image" == e2.type && (e2._hasCustomWidth = !!i2.dataset.width, e2._hasCustomHeight = !!i2.dataset.height), e2; 509 } }, { key: "checkSize", value: function(e2) { 510 return z(e2) ? "".concat(e2, "px") : e2; 511 } }, { key: "sanitizeValue", value: function(e2) { 512 return "true" !== e2 && "false" !== e2 ? e2 : "true" === e2; 513 } }]), V = i(function t2(i2, n2, s2) { 514 e(this, t2), this.element = i2, this.instance = n2, this.index = s2; 515 }, [{ key: "setContent", value: function() { 516 var e2 = this, t2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : null, i2 = arguments.length > 1 && void 0 !== arguments[1] && arguments[1]; 517 if (u(t2, "loaded")) 518 return false;
519 var n2 = this.instance.settings, s2 = this.slideConfig, l2 = T(); 520 C(n2.beforeSlideLoad) && n2.beforeSlideLoad({ index: this.index, slide: t2, player: false }); 521 var o2 = s2.type, r2 = s2.descPosition, a2 = t2.querySelector(".gslide-media"), h2 = t2.querySelector(".gslide-title"), c2 = t2.querySelector(".gslide-desc"), g2 = t2.querySelector(".gdesc-inner"), v2 = i2, f2 = "gSlideTitle_" + this.index, p2 = "gSlideDesc_" + this.index; 522 if (C(n2.afterSlideLoad) && (v2 = function() { 523 C(i2) && i2(), n2.afterSlideLoad({ index: e2.index, slide: t2, player: e2.instance.getSlidePlayerInstance(e2.index) }); 524 }), "" == s2.title && "" == s2.description ? g2 && g2.parentNode.parentNode.removeChild(g2.parentNode) : (h2 && "" !== s2.title ? (h2.id = f2, h2.innerHTML = s2.title) : h2.parentNode.removeChild(h2), c2 && "" !== s2.description ? (c2.id = p2, l2 && n2.moreLength > 0 ? (s2.smallDescription = this.slideShortDesc(s2.description, n2.moreLength, n2.moreText), c2.innerHTML = s2.smallDescription, this.descriptionEvents(c2, s2)) : c2.innerHTML = s2.description) : c2.parentNode.removeChild(c2), d(a2.parentNode, "desc-".concat(r2)), d(g2.parentNode, "description-".concat(r2))), d(a2, "gslide-".concat(o2)), d(t2, "loaded"), "video" !== o2) { 525 if ("external" !== o2) 526 return "inline" === o2 ? (B.apply(this.instance, [t2, s2, this.index, v2]), void (s2.draggable && new N({ dragEl: t2.querySelector(".gslide-inline"), toleranceX: n2.dragToleranceX, toleranceY: n2.dragToleranceY, slide: t2, instance: this.instance }))) : void ("image" !== o2 ? C(v2) && v2() : D(t2, s2, this.index, function() { 527 var i3 = t2.querySelector("img"); 528 s2.draggable && new N({ dragEl: i3, toleranceX: n2.dragToleranceX, toleranceY: n2.dragToleranceY, slide: t2, instance: e2.instance }), s2.zoomable && i3.naturalWidth > i3.offsetWidth && (d(i3, "zoomable"), new q(i3, t2, function() { 529 e2.instance.resize(); 530 })), C(v2) && v2(); 531 })); 532 H.apply(this, [t2, s2, this.index, v2]); 533 } else 534 _.apply(this.instance, [t2, s2, this.index, v2]); 535 } }
535, { key: "slideShortDesc", value: function(e2) { 536 var t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 50, i2 = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], n2 = document.createElement("div"); 537 n2.innerHTML = e2; 538 var s2 = n2.innerText, l2 = i2; 539 if ((e2 = s2.trim()).length <= t2) 540 return e2; 541 var o2 = e2.substr(0, t2 - 1); 542 return l2 ? (n2 = null, o2 + '... <a href="#" class="desc-more">' + i2 + "</a>") : o2; 543 } }, { key: "descriptionEvents", value: function(e2, t2) { 544 var i2 = this, n2 = e2.querySelector(".desc-more"); 545 if (!n2) 546 return false; 547 h("click", { onElement: n2, withCallback: function(e3, n3) { 548 e3.preventDefault(); 549 var s2 = document.body, l2 = g(n3, ".gslide-desc"); 550 if (!l2) 551 return false; 552 l2.innerHTML = t2.description, d(s2, "gdesc-open"); 553 var o2 = h("click", { onElement: [s2, g(l2, ".gslide-description")], withCallback: function(e4, n4) { 554 "a" !== e4.target.nodeName.toLowerCase() && (c(s2, "gdesc-open"), d(s2, "gdesc-closed"), l2.innerHTML = t2.smallDescription, i2.descriptionEvents(l2, t2), setTimeout(function() { 555 c(s2, "gdesc-closed"); 556 }, 400), o2.destroy()); 557 } }); 558 } }); 559 } }, { key: "create", value: function() { 560 return y(this.instance.settings.slideHTML); 561 } }, { key: "getConfig", value: function() { 562 E(this.element) || this.element.hasOwnProperty("draggable") || (this.element.draggable = this.instance.settings.draggable); 563 var e2 = new j(this.instance.settings.slideExtraAttributes); 564 return this.slideConfig = e2.parseConfig(this.element, this.instance.settings), this.slideConfig; 565 } }]); 566 function F(e2) { 567 return Math.sqrt(e2.x * e2.x + e2.y * e2.y); 568 } 569 function R(e2, t2) { 570 var i2 = function(e3, t3) { 571 var i3 = F(e3) * F(t3); 572 if (0 === i3) 573 return 0; 574 var n2 = function(e4, t4) { 575 return e4.x * t4.x + e4.y * t4.y; 576 }(e3, t3) / i3; 577 return n2 > 1 && (n2 = 1), Math.acos(n2); 578 }(e2, t2); 579 return function(e3, t3) { 580 return e3.x * t3.y - t3.x * e3.y; 581 }(e2, t2) > 0 && (i2 *= -1), 180 * i2 / Math.PI; 582 } 583 var G = i(function t2(i2) { 584 e(this, t2), this.handlers = [], this.el = i2; 585 }, [{ key: "add", value: function(e2) { 586 this.handlers.push(e2); 587 } }, { key: "del", value: function(e2) { 588 e2 || (this.handlers = []); 589 for (var t2 = this.handlers.length; t2 >= 0; t2--) 590 this.handlers[t2] === e2 && this.handlers.splice(t2, 1); 591 } }, { key: "dispatch", value: function() { 592 for (var e2 = 0, t2 = this.handlers.length; e2 < t2; e2++) { 593 var i2 = this.handlers[e2]; 594 "function" == typeof i2 && i2.apply(this.el, arguments); 595 } 596 } }]); 597 function Z(e2, t2) { 598 var i2 = new G(e2); 599 return i2.add(t2), i2; 600 } 601 var U = i(function t2(i2, n2) { 602 e(this, t2), this.element = "string" == typeof i2 ? document.querySelector(i2) : i2, this.start = this.start.bind(this), this.move = this.move.bind(this), this.end = this.end.bind(this), this.cancel = this.cancel.bind(this), this.element.addEventListener("touchstart", this.start, false), this.element.addEventListener("touchmove", this.move, false), this.element.addEventListener("touchend", this.end, false), this.element.addEventListener("touchcancel", this.cancel, false), this.preV = { x: null, y: null }, this.pinchStartLen = null, this.zoom = 1, this.isDoubleTap = false; 603 var s2 = function() { 604 }; 605 this.rotate = Z(this.element, n2.rotate || s2), this.touchStart = Z(this.element, n2.touchStart || s2), this.multipointStart = Z(this.element, n2.multipointStart || s2), this.multipointEnd = Z(this.element, n2.multipointEnd || s2), this.pinch = Z(this.element, n2.pinch || s2), this.swipe = Z(this.element, n2.swipe || s2), this.tap = Z(this.element, n2.tap || s2), this.doubleTap = Z(this.element, n2.doubleTap || s2), this.longTap = Z(this.element, n2.longTap || s2), this.singleTap = Z(this.element, n2.singleTap || s2), this.pressMove = Z(this.element, n2.pressMove || s2), this.twoFingerPressMove = Z(this.element, n2.twoFingerPressMove || s2), this.touchMove = Z(this.element, n2.touchMove || s2), this.touchEnd = Z(this.element, n2.touchEnd || s2), this.touchCancel = Z(this.element, n2.touchCancel || s2), this.translateContainer = this.element, this._cancelAllHandler = this.cancelAll.bind(this), window.addEventListener("scroll", this._cancelAllHandler), this.delta = null, this.last = null, this.now = null, this.tapTimeout = null, this.singleTapTimeout = null, this.longTapTimeout = null, this.swipeTimeout = null, this.x1 = this.x2 = this.y1 = this.y2 = null, this.preTapPosition = { x: null, y: null }; 606 }, [{ key: "start", value: function(e2) { 607 if (e2.touches) 608 if (e2.target && e2.target.nodeName && ["a", "button", "input"].indexOf(e2.target.nodeName.toLowerCase()) >= 0) 609 console.log("ignore drag for this touched element", e2.target.nodeName.toLowerCase()); 610 else { 611 this.now = Date.now(), this.x1 = e2.touches[0].pageX, this.y1 = e2.touches[0].pageY, this.delta = this.now - (this.last || this.now), this.touchStart.dispatch(e2, this.element), null !== this.preTapPosition.x && (this.isDoubleTap = this.delta > 0 && this.delta <= 250 && Math.abs(this.preTapPosition.x - this.x1) < 30 && Math.abs(this.preTapPosition.y - this.y1) < 30, this.isDoubleTap && clearTimeout(this.singleTapTimeout)), this.preTapPosition.x = this.x1, this.preTapPosition.y = this.y1, this.last = this.now; 612 var t2 = this.preV; 613 if (e2.touches.length > 1) { 614 this._cancelLongTap(), this._cancelSingleTap(); 615 var i2 = { x: e2.touches[1].pageX - this.x1, y: e2.touches[1].pageY - this.y1 }; 616 t2.x = i2.x, t2.y = i2.y, this.pinchStartLen = F(t2), this.multipointStart.dispatch(e2, this.element); 617 } 618 this._preventTap = false, this.longTapTimeout = setTimeout((function() { 619 this.longTap.dispatch(e2, this.element), this._preventTap = true; 620 }).bind(this), 750); 621 } 622 } }, { key: "move", value: function(e2) { 623 if (e2.touches) { 624 var t2 = this.preV, i2 = e2.touches.length, n2 = e2.touches[0].pageX, s2 = e2.touches[0].pageY; 625 if (this.isDoubleTap = false, i2 > 1) { 626 var l2 = e2.touches[1].pageX, o2 = e2.touches[1].pageY, r2 = { x: e2.touches[1].pageX - n2, y: e2.touches[1].pageY - s2 }; 627 null !== t2.x && (this.pinchStartLen > 0 && (e2.zoom = F(r2) / this.pinchStartLen, this.pinch.dispatch(e2, this.element)), e2.angle = R(r2, t2), this.rotate.dispatch(e2, this.element)), t2.x = r2.x, t2.y = r2.y, null !== this.x2 && null !== this.sx2 ? (e2.deltaX = (n2 - this.x2 + l2 - this.sx2) / 2, e2.deltaY = (s2 - this.y2 + o2 - this.sy2) / 2) : (e2.deltaX = 0, e2.deltaY = 0), this.twoFingerPressMove.dispatch(e2, this.element), this.sx2 = l2, this.sy2 = o2; 628 } else { 629 if (null !== this.x2) { 630 e2.deltaX = n2 - this.x2, e2.deltaY = s2 - this.y2; 631 var a2 = Math.abs(this.x1 - this.x2), h2 = Math.abs(this.y1 - this.y2); 632 (a2 > 10 || h2 > 10) && (this._preventTap = true); 633 } else 634 e2.deltaX = 0, e2.deltaY = 0; 635 this.pressMove.dispatch(e2, this.element); 636 } 637 this.touchMove.dispatch(e2, this.element), this._cancelLongTap(), this.x2 = n2, this.y2 = s2, i2 > 1 && e2.preventDefault(); 638 } 639 } }, { key: "end", value: function(e2) { 640 if (e2.changedTouches) { 641 this._cancelLongTap(); 642 var t2 = this; 643 e2.touches.length < 2 && (this.multipointEnd.dispatch(e2, this.element), this.sx2 = this.sy2 = null), this.x2 && Math.abs(this.x1 - this.x2) > 30 || this.y2 && Math.abs(this.y1 - this.y2) > 30 ? (e2.direction = this._swipeDirection(this.x1, this.x2, this.y1, this.y2), this.swipeTimeout = setTimeout(function() { 644 t2.swipe.dispatch(e2, t2.element); 645 }, 0)) : (this.tapTimeout = setTimeout(function() { 646 t2._preventTap || t2.tap.dispatch(e2, t2.element), t2.isDoubleTap && (t2.doubleTap.dispatch(e2, t2.element), t2.isDoubleTap = false); 647 }, 0), t2.isDoubleTap || (t2.singleTapTimeout = setTimeout(function() { 648 t2.singleTap.dispatch(e2, t2.element); 649 }, 250))), this.touchEnd.dispatch(e2, this.element), this.preV.x = 0, this.preV.y = 0, this.zoom = 1, this.pinchStartLen = null, this.x1 = this.x2 = this.y1 = this.y2 = null; 650 } 651 } }, { key: "cancelAll", value: function() { 652 this._preventTap = true, clearTimeout(this.singleTapTimeout), clearTimeout(this.tapTimeout), clearTimeout(this.longTapTimeout), clearTimeout(this.swipeTimeout); 653 } }, { key: "cancel", value: function(e2) { 654 this.cancelAll(), this.touchCancel.dispatch(e2, this.element); 655 } }, { key: "_cancelLongTap", value: function() { 656 clearTimeout(this.longTapTimeout); 657 } }, { key: "_cancelSingleTap", value: function() { 658 clearTimeout(this.singleTapTimeout); 659 } }, { key: "_swipeDirection", value: function(e2, t2, i2, n2) { 660 return Math.abs(e2 - t2) >= Math.abs(i2 - n2) ? e2 - t2 > 0 ? "Left" : "Right" : i2 - n2 > 0 ? "Up" : "Down"; 661 } }, { key: "on", value: function(e2, t2) { 662 this[e2] && this[e2].add(t2); 663 } }, { key: "off", value: function(e2, t2) { 664 this[e2] && this[e2].del(t2); 665 } }
665, { key: "destroy", value: function() { 666 return this.singleTapTimeout && clearTimeout(this.singleTapTimeout), this.tapTimeout && clearTimeout(this.tapTimeout), this.longTapTimeout && clearTimeout(this.longTapTimeout), this.swipeTimeout && clearTimeout(this.swipeTimeout), this.element.removeEventListener("touchstart", this.start), this.element.removeEventListener("touchmove", this.move), this.element.removeEventListener("touchend", this.end), this.element.removeEventListener("touchcancel", this.cancel), this.rotate.del(), this.touchStart.del(), this.multipointStart.del(), this.multipointEnd.del(), this.pinch.del(), this.swipe.del(), this.tap.del(), this.doubleTap.del(), this.longTap.del(), this.singleTap.del(), this.pressMove.del(), this.twoFingerPressMove.del(), this.touchMove.del(), this.touchEnd.del(), this.touchCancel.del(), this.preV = this.pinchStartLen = this.zoom = this.isDoubleTap = this.delta = this.last = this.now = this.tapTimeout = this.singleTapTimeout = this.longTapTimeout = this.swipeTimeout = this.x1 = this.x2 = this.y1 = this.y2 = this.preTapPosition = this.rotate = this.touchStart = this.multipointStart = this.multipointEnd = this.pinch = this.swipe = this.tap = this.doubleTap = this.longTap = this.singleTap = this.pressMove = this.touchMove = this.touchEnd = this.touchCancel = this.twoFingerPressMove = null, window.removeEventListener("scroll", this._cancelAllHandler), null; 667 } }]); 668 function $(e2) { 669 var t2 = function() { 670 var e3, t3 = document.createElement("fakeelement"), i3 = { transition: "transitionend", OTransition: "oTransitionEnd", MozTransition: "transitionend", WebkitTransition: "webkitTransitionEnd" }; 671 for (e3 in i3) 672 if (void 0 !== t3.style[e3]) 673 return i3[e3]; 674 }(), i2 = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth, n2 = u(e2, "gslide-media") ? e2 : e2.querySelector(".gslide-media"), s2 = g(n2, ".ginner-container"), l2 = e2.querySelector(".gslide-description"); 675 i2 > 769 && (n2 = s2), d(n2, "greset"), f(n2, "translate3d(0, 0, 0)"), h(t2, { onElement: n2, once: true, withCallback: function(e3, t3) { 676 c(n2, "greset"); 677 } }), n2.style.opacity = "", l2 && (l2.style.opacity = ""); 678 } 679 function J(e2) { 680 if (e2.events.hasOwnProperty("touch")) 681 return false; 682 var t2, i2, n2, s2 = x(), l2 = s2.width, o2 = s2.height, r2 = false, a2 = null, h2 = null, v2 = null, p2 = false, m2 = 1, y2 = 1, b2 = false, S2 = false, w2 = null, T2 = null, C2 = null, k2 = null, E2 = 0, A2 = 0, L2 = false, I2 = false, O2 = {}, P2 = {}, M2 = 0, z2 = 0, X2 = document.getElementById("glightbox-slider"), Y2 = document.querySelector(".goverlay"), q2 = new U(X2, { touchStart: function(t3) { 683 if (r2 = true, (u(t3.targetTouches[0].target, "ginner-container") || g(t3.targetTouches[0].target, ".gslide-desc") || "a" == t3.targetTouches[0].target.nodeName.toLowerCase()) && (r2 = false), g(t3.targetTouches[0].target, ".gslide-inline") && !u(t3.targetTouches[0].target.parentNode, "gslide-inline") && (r2 = false), r2) { 684 if (P2 = t3.targetTouches[0], O2.pageX = t3.targetTouches[0].pageX, O2.pageY = t3.targetTouches[0].pageY, M2 = t3.targetTouches[0].clientX, z2 = t3.targetTouches[0].clientY, a2 = e2.activeSlide, h2 = a2.querySelector(".gslide-media"), n2 = a2.querySelector(".gslide-inline"), v2 = null, u(h2, "gslide-image") && (v2 = h2.querySelector("img")), (window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth) > 769 && (h2 = a2.querySelector(".ginner-container")), c(Y2, "greset"), t3.pageX > 20 && t3.pageX < window.innerWidth - 20) 685 return; 686 t3.preventDefault(); 687 } 688 }, touchMove: function(s3) { 689 if (r2 && (P2 = s3.targetTouches[0], !b2 && !S2)) { 690 if (n2 && n2.offsetHeight > o2) { 691 var a3 = O2.pageX - P2.pageX; 692 if (Math.abs(a3) <= 13) 693 return false; 694 } 695 p2 = true; 696 var d2, c2 = s3.targetTouches[0].clientX, u2 = s3.targetTouches[0].clientY, g2 = M2 - c2, m3 = z2 - u2; 697 if (Math.abs(g2) > Math.abs(m3) ? (L2 = false, I2 = true) : (I2 = false, L2 = true), t2 = P2.pageX - O2.pageX, E2 = 100 * t2 / l2, i2 = P2.pageY - O2.pageY, A2 = 100 * i2 / o2, L2 && v2 && (d2 = 1 - Math.abs(i2) / o2, Y2.style.opacity = d2, e2.settings.touchFollowAxis && (E2 = 0)), I2 && (d2 = 1 - Math.abs(t2) / l2, h2.style.opacity = d2, e2.settings.touchFollowAxis && (A2 = 0)), !v2) 698 return f(h2, "translate3d(".concat(E2, "%, 0, 0)")); 699 f(h2, "translate3d(".concat(E2, "%, ").concat(A2, "%, 0)")); 700 } 701 }, touchEnd: function() { 702 if (r2) { 703 if (p2 = false, S2 || b2) 704 return C2 = w2, void (k2 = T2); 705 var t3 = Math.abs(parseInt(A2)), i3 = Math.abs(parseInt(E2)); 706 if (!(t3 > 29 && v2)) 707 return t3 < 29 && i3 < 25 ? (d(Y2, "greset"), Y2.style.opacity = 1, $(h2)) : void 0; 708 e2.close(); 709 } 710 }, multipointEnd: function() { 711 setTimeout(function() { 712 b2 = false;
713 }, 50); 714 }, multipointStart: function() { 715 b2 = true, m2 = y2 || 1; 716 }, pinch: function(e3) { 717 if (!v2 || p2) 718 return false; 719 b2 = true, v2.scaleX = v2.scaleY = m2 * e3.zoom; 720 var t3 = m2 * e3.zoom; 721 if (S2 = true, t3 <= 1) 722 return S2 = false, t3 = 1, k2 = null, C2 = null, w2 = null, T2 = null, void v2.setAttribute("style", ""); 723 t3 > 4.5 && (t3 = 4.5), v2.style.transform = "scale3d(".concat(t3, ", ").concat(t3, ", 1)"), y2 = t3; 724 }, pressMove: function(e3) { 725 if (S2 && !b2) { 726 var t3 = P2.pageX - O2.pageX, i3 = P2.pageY - O2.pageY; 727 C2 && (t3 += C2), k2 && (i3 += k2), w2 = t3, T2 = i3; 728 var n3 = "translate3d(".concat(t3, "px, ").concat(i3, "px, 0)"); 729 y2 && (n3 += " scale3d(".concat(y2, ", ").concat(y2, ", 1)")), f(v2, n3); 730 } 731 }, swipe: function(t3) { 732 if (!S2) 733 if (b2) 734 b2 = false; 735 else { 736 if ("Left" == t3.direction) { 737 if (e2.index == e2.elements.length - 1) 738 return $(h2); 739 e2.nextSlide(); 740 } 741 if ("Right" == t3.direction) { 742 if (0 == e2.index) 743 return $(h2); 744 e2.prevSlide(); 745 } 746 } 747 } }); 748 e2.events.touch = q2; 749 } 750 var K = T(), Q = null !== T() || void 0 !== document.createTouch || "ontouchstart" in window || "onmsgesturechange" in window || navigator.msMaxTouchPoints, ee = document.getElementsByTagName("html")[0], te = { selector: ".glightbox", elements: null, skin: "clean", theme: "clean", closeButton: true, startAt: null, autoplayVideos: true, autofocusVideos: true, descPosition: "bottom", width: "900px", height: "506px", videosWidth: "960px", beforeSlideChange: null, afterSlideChange: null, beforeSlideLoad: null, afterSlideLoad: null, slideInserted: null, slideRemoved: null, slideExtraAttributes: null, onOpen: null, onClose: null, loop: false, zoomable: true, draggable: true, dragAutoSnap: false, dragToleranceX: 40, dragToleranceY: 65, preload: true, oneSlidePerOpen: false, touchNavigation: true, touchFollowAxis: true, keyboardNavigation: true, closeOnOutsideClick: true, plugins: false, plyr: { css: "https://cdn.plyr.io/3.6.12/plyr.css", js: "https://cdn.plyr.io/3.6.12/plyr.js", config: { ratio: "16:9", fullscreen: { enabled: true, iosNative: true }, youtube: { noCookie: true, rel: 0, showinfo: 0, iv_load_policy: 3 }, vimeo: { byline: false, portrait: false, title: false, transparent: false } } }, openEffect: "zoom", closeEffect: "zoom", slideEffect: "slide", moreText: "See more", moreLength: 60, cssEfects: { fade: { in: "fadeIn", out: "fadeOut" }, zoom: { in: "zoomIn", out: "zoomOut" }, slide: { in: "slideInRight", out: "slideOutLeft" }, slideBack: { in: "slideInLeft", out: "slideOutRight" }, none: { in: "none", out: "none" } }, svg: { close: '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 512 512" xml:space="preserve"><g><g><path d="M505.943,6.058c-8.077-8.077-21.172-8.077-29.249,0L6.058,476.693c-8.077,8.077-8.077,21.172,0,29.249C10.096,509.982,15.39,512,20.683,512c5.293,0,10.586-2.019,14.625-6.059L505.943,35.306C514.019,27.23,514.019,14.135,505.943,6.058z"/></g></g><g><g><path d="M505.942,476.694L35.306,6.059c-8.076-8.077-21.172-8.077-29.248,0c-8.077,8.076-8.077,21.171,0,29.248l470.636,470.636c4.038,4.039,9.332,6.058,14.625,6.058c5.293,0,10.587-2.019,14.624-6.057C514.018,497.866,514.018,484.771,505.942,476.694z"/></g></g></svg>', next: '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 477.175 477.175" xml:space="preserve"> <g><path d="M360.731,229.075l-225.1-225.1c-5.3-5.3-13.8-5.3-19.1,0s-5.3,13.8,0,19.1l215.5,215.5l-215.5,215.5c-5.3,5.3-5.3,13.8,0,19.1c2.6,2.6,6.1,4,9.5,4c3.4,0,6.9-1.3,9.5-4l225.1-225.1C365.931,242.875,365.931,234.275,360.731,229.075z"/></g></svg>', prev: '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 477.175 477.175" xml:space="preserve"><g><path d="M145.188,238.575l215.5-215.5c5.3-5.3,5.3-13.8,0-19.1s-13.8-5.3-19.1,0l-225.1,225.1c-5.3,5.3-5.3,13.8,0,19.1l225.1,225c2.6,2.6,6.1,4,9.5,4s6.9-1.3,9.5-4c5.3-5.3,5.3-13.8,0-19.1L145.188,238.575z"/></g></svg>' }, slideHTML: '<div class="gslide">\n <div class="gslide-inner-content">\n <div class="ginner-container">\n <div class="gslide-media">\n </div>\n <div class="gslide-description">\n <div class="gdesc-inner">\n <h4 class="gslide-title"></h4>\n <div class="gslide-desc"></div>\n </div>\n </div>\n </div>\n </div>\n</div>', lightboxHTML: '<div id="glightbox-body" class="glightbox-container" tabindex="-1" role="dialog" aria-hidden="false">\n <div class="gloader visible"></div>\n <div class="goverlay"></div>\n <div class="gcontainer">\n <div id="glightbox-slider" class="gslider"></div>\n <button class="gclose gbtn" aria-label="Close" data-taborder="3">{closeSVG}</button>\n <button class="gprev gbtn" aria-label="Previous" data-taborder="2">{prevSVG}</button>\n <button class="gnext gbtn" aria-label="Next" data-taborder="1">{nextSVG}</button>\n</div>\n</div>' }, ie = i(function t2() { 751 var i2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}; 752 e(this, t2), this.customOptions = i2, this.settings = o(te, i2), this.effectsClasses = this.getAnimationClasses(), this.videoPlayers = {}, this.apiEvents = [], this.fullElementsList = false;
753 }, [{ key: "init", value: function() { 754 var e2 = this, t2 = this.getSelector(); 755 t2 && (this.baseEvents = h("click", { onElement: t2, withCallback: function(t3, i2) { 756 t3.preventDefault(), e2.open(i2); 757 } })), this.elements = this.getElements(); 758 } }, { key: "open", value: function() { 759 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : null, t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : null; 760 if (0 === this.elements.length) 761 return false; 762 this.activeSlide = null, this.prevActiveSlideIndex = null, this.prevActiveSlide = null; 763 var i2 = z(t2) ? t2 : this.settings.startAt; 764 if (E(e2)) { 765 var n2 = e2.getAttribute("data-gallery"); 766 n2 && (this.fullElementsList = this.elements, this.elements = this.getGalleryElements(this.elements, n2)), O(i2) && (i2 = this.getElementIndex(e2)) < 0 && (i2 = 0); 767 } 768 z(i2) || (i2 = 0), this.build(), v(this.overlay, "none" === this.settings.openEffect ? "none" : this.settings.cssEfects.fade.in); 769 var s2 = document.body, l2 = window.innerWidth - document.documentElement.clientWidth; 770 if (l2 > 0) { 771 var o2 = document.createElement("style"); 772 o2.type = "text/css", o2.className = "gcss-styles", o2.innerText = ".gscrollbar-fixer {margin-right: ".concat(l2, "px}"), document.head.appendChild(o2), d(s2, "gscrollbar-fixer"); 773 } 774 d(s2, "glightbox-open"), d(ee, "glightbox-open"), K && (d(document.body, "glightbox-mobile"), this.settings.slideEffect = "slide"), this.showSlide(i2, true), 1 === this.elements.length ? (d(this.prevButton, "glightbox-button-hidden"), d(this.nextButton, "glightbox-button-hidden")) : (c(this.prevButton, "glightbox-button-hidden"), c(this.nextButton, "glightbox-button-hidden")), this.lightboxOpen = true, this.trigger("open"), C(this.settings.onOpen) && this.settings.onOpen(), Q && this.settings.touchNavigation && J(this), this.settings.keyboardNavigation && Y(this); 775 } }, { key: "openAt", value: function() { 776 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 0; 777 this.open(null, e2); 778 } }, { key: "showSlide", value: function() { 779 var e2 = this, t2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 0, i2 = arguments.length > 1 && void 0 !== arguments[1] && arguments[1]; 780 p(this.loader), this.index = parseInt(t2); 781 var n2 = this.slidesContainer.querySelector(".current"); 782 n2 && c(n2, "current"), this.slideAnimateOut(); 783 var s2 = this.slidesContainer.querySelectorAll(".gslide")[t2]; 784 if (u(s2, "loaded")) 785 this.slideAnimateIn(s2, i2), m(this.loader); 786 else { 787 p(this.loader); 788 var l2 = this.elements[t2], o2 = { index: this.index, slide: s2, slideNode: s2, slideConfig: l2.slideConfig, slideIndex: this.index, trigger: l2.node, player: null }; 789 this.trigger("slide_before_load", o2), l2.instance.setContent(s2, function() { 790 m(e2.loader), e2.resize(), e2.slideAnimateIn(s2, i2), e2.trigger("slide_after_load", o2); 791 }); 792 } 793 this.slideDescription = s2.querySelector(".gslide-description"), this.slideDescriptionContained = this.slideDescription && u(this.slideDescription.parentNode, "gslide-media"), this.settings.preload && (this.preloadSlide(t2 + 1), this.preloadSlide(t2 - 1)), this.updateNavigationClasses(), this.activeSlide = s2; 794 } }, { key: "preloadSlide", value: function(e2) { 795 var t2 = this; 796 if (e2 < 0 || e2 > this.elements.length - 1) 797 return false; 798 if (O(this.elements[e2])) 799 return false; 800 var i2 = this.slidesContainer.querySelectorAll(".gslide")[e2]; 801 if (u(i2, "loaded")) 802 return false; 803 var n2 = this.elements[e2], s2 = n2.type, l2 = { index: e2, slide: i2, slideNode: i2, slideConfig: n2.slideConfig, slideIndex: e2, trigger: n2.node, player: null }; 804 this.trigger("slide_before_load", l2), "video" === s2 || "external" === s2 ? setTimeout(function() { 805 n2.instance.setContent(i2, function() { 806 t2.trigger("slide_after_load", l2); 807 }); 808 }, 200) : n2.instance.setContent(i2, function() { 809 t2.trigger("slide_after_load", l2); 810 }); 811 } }, { key: "prevSlide", value: function() { 812 this.goToSlide(this.index - 1); 813 } }, { key: "nextSlide", value: function() { 814 this.goToSlide(this.index + 1); 815 } }, { key: "goToSlide", value: function() { 816 var e2 = arguments.length > 0 && void 0 !== arguments[0] && arguments[0]; 817 if (this.prevActiveSlide = this.activeSlide, this.prevActiveSlideIndex = this.index, !this.loop() && (e2 < 0 || e2 > this.elements.length - 1)) 818 return false;
819 e2 < 0 ? e2 = this.elements.length - 1 : e2 >= this.elements.length && (e2 = 0), this.showSlide(e2); 820 } }, { key: "insertSlide", value: function() { 821 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, t2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : -1; 822 t2 < 0 && (t2 = this.elements.length); 823 var i2 = new V(e2, this, t2), n2 = i2.getConfig(), s2 = o({}, n2), l2 = i2.create(), r2 = this.elements.length - 1; 824 s2.index = t2, s2.node = false, s2.instance = i2, s2.slideConfig = n2, this.elements.splice(t2, 0, s2); 825 var a2 = null, h2 = null; 826 if (this.slidesContainer) { 827 if (t2 > r2) 828 this.slidesContainer.appendChild(l2); 829 else { 830 var d2 = this.slidesContainer.querySelectorAll(".gslide")[t2]; 831 this.slidesContainer.insertBefore(l2, d2); 832 } 833 (this.settings.preload && 0 == this.index && 0 == t2 || this.index - 1 == t2 || this.index + 1 == t2) && this.preloadSlide(t2), 0 === this.index && 0 === t2 && (this.index = 1), this.updateNavigationClasses(), a2 = this.slidesContainer.querySelectorAll(".gslide")[t2], h2 = this.getSlidePlayerInstance(t2), s2.slideNode = a2; 834 } 835 this.trigger("slide_inserted", { index: t2, slide: a2, slideNode: a2, slideConfig: n2, slideIndex: t2, trigger: null, player: h2 }), C(this.settings.slideInserted) && this.settings.slideInserted({ index: t2, slide: a2, player: h2 }); 836 } }, { key: "removeSlide", value: function() { 837 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : -1; 838 if (e2 < 0 || e2 > this.elements.length - 1) 839 return false; 840 var t2 = this.slidesContainer && this.slidesContainer.querySelectorAll(".gslide")[e2]; 841 t2 && (this.getActiveSlideIndex() == e2 && (e2 == this.elements.length - 1 ? this.prevSlide() : this.nextSlide()), t2.parentNode.removeChild(t2)), this.elements.splice(e2, 1), this.trigger("slide_removed", e2), C(this.settings.slideRemoved) && this.settings.slideRemoved(e2); 842 } }, { key: "slideAnimateIn", value: function(e2, t2) { 843 var i2 = this, n2 = e2.querySelector(".gslide-media"), s2 = e2.querySelector(".gslide-description"), l2 = { index: this.prevActiveSlideIndex, slide: this.prevActiveSlide, slideNode: this.prevActiveSlide, slideIndex: this.prevActiveSlide, slideConfig: O(this.prevActiveSlideIndex) ? null : this.elements[this.prevActiveSlideIndex].slideConfig, trigger: O(this.prevActiveSlideIndex) ? null : this.elements[this.prevActiveSlideIndex].node, player: this.getSlidePlayerInstance(this.prevActiveSlideIndex) }, o2 = { index: this.index, slide: this.activeSlide, slideNode: this.activeSlide, slideConfig: this.elements[this.index].slideConfig, slideIndex: this.index, trigger: this.elements[this.index].node, player: this.getSlidePlayerInstance(this.index) }; 844 if (n2.offsetWidth > 0 && s2 && (m(s2), s2.style.display = ""), c(e2, this.effectsClasses), t2) 845 v(e2, this.settings.cssEfects[this.settings.openEffect].in, function() { 846 i2.settings.autoplayVideos && i2.slidePlayerPlay(e2), i2.trigger("slide_changed", { prev: l2, current: o2 }), C(i2.settings.afterSlideChange) && i2.settings.afterSlideChange.apply(i2, [l2, o2]); 847 }); 848 else { 849 var r2 = this.settings.slideEffect, a2 = "none" !== r2 ? this.settings.cssEfects[r2].in : r2; 850 this.prevActiveSlideIndex > this.index && "slide" == this.settings.slideEffect && (a2 = this.settings.cssEfects.slideBack.in), v(e2, a2, function() { 851 i2.settings.autoplayVideos && i2.slidePlayerPlay(e2), i2.trigger("slide_changed", { prev: l2, current: o2 }), C(i2.settings.afterSlideChange) && i2.settings.afterSlideChange.apply(i2, [l2, o2]); 852 }); 853 } 854 setTimeout(function() { 855 i2.resize(e2); 856 }, 100), d(e2, "current"); 857 } }, { key: "slideAnimateOut", value: function() { 858 if (!this.prevActiveSlide) 859 return false; 860 var e2 = this.prevActiveSlide; 861 c(e2, this.effectsClasses), d(e2, "prev"); 862 var t2 = this.settings.slideEffect, i2 = "none" !== t2 ? this.settings.cssEfects[t2].out : t2; 863 this.slidePlayerPause(e2), this.trigger("slide_before_change", { prev: { index: this.prevActiveSlideIndex, slide: this.prevActiveSlide, slideNo
863de: this.prevActiveSlide, slideIndex: this.prevActiveSlideIndex, slideConfig: O(this.prevActiveSlideIndex) ? null : this.elements[this.prevActiveSlideIndex].slideConfig, trigger: O(this.prevActiveSlideIndex) ? null : this.elements[this.prevActiveSlideIndex].node, player: this.getSlidePlayerInstance(this.prevActiveSlideIndex) }, current: { index: this.index, slide: this.activeSlide, slideNode: this.activeSlide, slideIndex: this.index, slideConfig: this.elements[this.index].slideConfig, trigger: this.elements[this.index].node, player: this.getSlidePlayerInstance(this.index) } }), C(this.settings.beforeSlideChange) && this.settings.beforeSlideChange.apply(this, [{ index: this.prevActiveSlideIndex, slide: this.prevActiveSlide, player: this.getSlidePlayerInstance(this.prevActiveSlideIndex) }, { index: this.index, slide: this.activeSlide, player: this.getSlidePlayerInstance(this.index) }]), this.prevActiveSlideIndex > this.index && "slide" == this.settings.slideEffect && (i2 = this.settings.cssEfects.slideBack.out), v(e2, i2, function() { 864 var t3 = e2.querySelector(".ginner-container"), i3 = e2.querySelector(".gslide-media"), n2 = e2.querySelector(".gslide-description"); 865 t3.style.transform = "", i3.style.transform = "", c(i3, "greset"), i3.style.opacity = "", n2 && (n2.style.opacity = ""), c(e2, "prev"); 866 }); 867 } }, { key: "getAllPlayers", value: function() { 868 return this.videoPlayers; 869 } }, { key: "getSlidePlayerInstance", value: function(e2) { 870 var t2 = "gvideo" + e2, i2 = this.getAllPlayers(); 871 return !(!P(i2, t2) || !i2[t2]) && i2[t2]; 872 } }, { key: "stopSlideVideo", value: function(e2) { 873 if (E(e2)) { 874 var t2 = e2.querySelector(".gvideo-wrapper"); 875 t2 && (e2 = t2.getAttribute("data-index")); 876 } 877 console.log("stopSlideVideo is deprecated, use slidePlayerPause"); 878 var i2 = this.getSlidePlayerInstance(e2); 879 i2 && i2.playing && i2.pause(); 880 } }, { key: "slidePlayerPause", value: function(e2) { 881 if (E(e2)) { 882 var t2 = e2.querySelector(".gvideo-wrapper"); 883 t2 && (e2 = t2.getAttribute("data-index")); 884 } 885 var i2 = this.getSlidePlayerInstance(e2); 886 i2 && i2.playing && i2.pause(); 887 } }, { key: "playSlideVideo", value: function(e2) { 888 if (E(e2)) { 889 var t2 = e2.querySelector(".gvideo-wrapper"); 890 t2 && (e2 = t2.getAttribute("data-index")); 891 } 892 console.log("playSlideVideo is deprecated, use slidePlayerPlay"); 893 var i2 = this.getSlidePlayerInstance(e2); 894 i2 && !i2.playing && i2.play(); 895 } }, { key: "slidePlayerPlay", value: function(e2) { 896 var t2; 897 if (!K || null !== (t2 = this.settings.plyr.config) && void 0 !== t2 && t2.muted) { 898 if (E(e2)) { 899 var i2 = e2.querySelector(".gvideo-wrapper"); 900 i2 && (e2 = i2.getAttribute("data-index")); 901 } 902 var n2 = this.getSlidePlayerInstance(e2); 903 n2 && !n2.playing && (n2.play(), this.settings.autofocusVideos && n2.elements.container.focus()); 904 } 905 } }, { key: "setElements", value: function(e2) { 906 var t2 = this; 907 this.settings.elements = false; 908 var i2 = []; 909 e2 && e2.length && r(e2, function(e3, n2) { 910 var s2 = new V(e3, t2, n2), l2 = s2.getConfig(), r2 = o({}, l2); 911 r2.slideConfig = l2, r2.instance = s2, r2.index = n2, i2.push(r2); 912 }), this.elements = i2, this.lightboxOpen && (this.slidesContainer.innerHTML = "", this.elements.length && (r(this.elements, function() { 913 var e3 = y(t2.settings.slideHTML); 914 t2.slidesContainer.appendChild(e3); 915 }), this.showSlide(0, true))); 916 } }, { key: "getElementIndex", value: function(e2) { 917 var t2 = false; 918 return r(this.elements, function(i2, n2) { 919 if (P(i2, "node") && i2.node == e2) 920 return t2 = n2, true; 921 }), t2; 922 } }, { key: "getElements", value: function() { 923 var e2 = this, t2 = []; 924 this.elements = this.elements ? this.elements : [], !O(this.settings.elements) && A(this.settings.elements) && this.settings.elements.length && r(this.settings.elements, function(i3, n2) { 925 var s2 = new V(i3, e2, n2), l2 = s2.getConfig(), r2 = o({}, l2); 926 r2.node = false, r2.index = n2, r2.instance = s2, r2.slideConfig = l2, t2.push(r2); 927 }); 928 var i2 = false;
929 return this.getSelector() && (i2 = document.querySelectorAll(this.getSelector())), i2 ? (r(i2, function(i3, n2) { 930 var s2 = new V(i3, e2, n2), l2 = s2.getConfig(), r2 = o({}, l2); 931 r2.node = i3, r2.index = n2, r2.instance = s2, r2.slideConfig = l2, r2.gallery = i3.getAttribute("data-gallery"), t2.push(r2); 932 }), t2) : t2; 933 } }, { key: "getGalleryElements", value: function(e2, t2) { 934 return e2.filter(function(e3) { 935 return e3.gallery == t2; 936 }); 937 } }, { key: "getSelector", value: function() { 938 return !this.settings.elements && (this.settings.selector && "data-" == this.settings.selector.substring(0, 5) ? "*[".concat(this.settings.selector, "]") : this.settings.selector); 939 } }, { key: "getActiveSlide", value: function() { 940 return this.slidesContainer.querySelectorAll(".gslide")[this.index]; 941 } }, { key: "getActiveSlideIndex", value: function() { 942 return this.index; 943 } }, { key: "getAnimationClasses", value: function() { 944 var e2 = []; 945 for (var t2 in this.settings.cssEfects) 946 if (this.settings.cssEfects.hasOwnProperty(t2)) { 947 var i2 = this.settings.cssEfects[t2]; 948 e2.push("g".concat(i2.in)), e2.push("g".concat(i2.out)); 949 } 950 return e2.join(" "); 951 } }, { key: "build", value: function() { 952 var e2 = this; 953 if (this.built) 954 return false; 955 var t2 = document.body.childNodes, i2 = []; 956 r(t2, function(e3) { 957 e3.parentNode == document.body && "#" !== e3.nodeName.charAt(0) && e3.hasAttribute && !e3.hasAttribute("aria-hidden") && (i2.push(e3), e3.setAttribute("aria-hidden", "true")); 958 }); 959 var n2 = P(this.settings.svg, "next") ? this.settings.svg.next : "", s2 = P(this.settings.svg, "prev") ? this.settings.svg.prev : "", l2 = P(this.settings.svg, "close") ? this.settings.svg.close : "", o2 = this.settings.lightboxHTML; 960 o2 = y(o2 = (o2 = (o2 = o2.replace(/{nextSVG}/g, n2)).replace(/{prevSVG}/g, s2)).replace(/{closeSVG}/g, l2)), document.body.appendChild(o2); 961 var a2 = document.getElementById("glightbox-body"); 962 this.modal = a2; 963 var c2 = a2.querySelector(".gclose"); 964 this.prevButton = a2.querySelector(".gprev"), this.nextButton = a2.querySelector(".gnext"), this.overlay = a2.querySelector(".goverlay"), this.loader = a2.querySelector(".gloader"), this.slidesContainer = document.getElementById("glightbox-slider"), this.bodyHiddenChildElms = i2, this.events = {}, d(this.modal, "glightbox-" + this.settings.skin), this.settings.closeButton && c2 && (this.events.close = h("click", { onElement: c2, withCallback: function(t3, i3) { 965 t3.preventDefault(), e2.close(); 966 } })), c2 && !this.settings.closeButton && c2.parentNode.removeChild(c2), this.nextButton && (this.events.next = h("click", { onElement: this.nextButton, withCallback: function(t3, i3) { 967 t3.preventDefault(), e2.nextSlide(); 968 } })), this.prevButton && (this.events.prev = h("click", { onElement: this.prevButton, withCallback: function(t3, i3) { 969 t3.preventDefault(), e2.prevSlide(); 970 } })), this.settings.closeOnOutsideClick && (this.events.outClose = h("click", { onElement: a2, withCallback: function(t3, i3) { 971 e2.preventOutsideClick || u(document.body, "glightbox-mobile") || g(t3.target, ".ginner-container") || g(t3.target, ".gbtn") || u(t3.target, "gnext") || u(t3.target, "gprev") || e2.close(); 972 } })), r(this.elements, function(t3, i3) { 973 e2.slidesContainer.appendChild(t3.instance.create()), t3.slideNode = e2.slidesContainer.querySelectorAll(".gslide")[i3]; 974 }), Q && d(document.body, "glightbox-touch"), this.events.resize = h("resize", { onElement: window, withCallback: function() { 975 e2.resize(); 976 } }), this.built = true; 977 } }, { key: "resize", value: function() { 978 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : null; 979 if ((e2 = e2 || this.activeSlide) && !u(e2, "zoomed")) { 980 var t2 = x(), i2 = e2.querySelector(".gvideo-wrapper"), n2 = e2.querySelector(".gslide-image"), s2 = this.slideDescription, l2 = t2.width, o2 = t2.he
980ight; 981 if (l2 <= 768 ? d(document.body, "glightbox-mobile") : c(document.body, "glightbox-mobile"), i2 || n2) { 982 var r2 = false; 983 if (s2 && (u(s2, "description-bottom") || u(s2, "description-top")) && !u(s2, "gabsolute") && (r2 = true), n2) { 984 if (l2 <= 768) 985 n2.querySelector("img"); 986 else if (r2) { 987 var a2, h2, g2 = s2.offsetHeight, v2 = n2.querySelector("img"), f2 = null === (a2 = this.elements[this.index]) || void 0 === a2 ? void 0 : a2.node, p2 = "100vh"; 988 f2 && (p2 = null !== (h2 = f2.getAttribute("data-height")) && void 0 !== h2 ? h2 : p2), v2.setAttribute("style", "max-height: calc(".concat(p2, " - ").concat(g2, "px)")), s2.setAttribute("style", "max-width: ".concat(v2.offsetWidth, "px;")); 989 } 990 } 991 if (i2) { 992 var m2 = P(this.settings.plyr.config, "ratio") ? this.settings.plyr.config.ratio : ""; 993 if (!m2) { 994 var y2 = i2.clientWidth, b2 = i2.clientHeight, S2 = y2 / b2; 995 m2 = "".concat(y2 / S2, ":").concat(b2 / S2); 996 } 997 var w2 = m2.split(":"), T2 = this.settings.videosWidth, C2 = this.settings.videosWidth, k2 = (C2 = z(T2) || -1 !== T2.indexOf("px") ? parseInt(T2) : -1 !== T2.indexOf("vw") ? l2 * parseInt(T2) / 100 : -1 !== T2.indexOf("vh") ? o2 * parseInt(T2) / 100 : -1 !== T2.indexOf("%") ? l2 * parseInt(T2) / 100 : parseInt(i2.clientWidth)) / (parseInt(w2[0]) / parseInt(w2[1])); 998 if (k2 = Math.floor(k2), r2 && (o2 -= s2.offsetHeight), C2 > l2 || k2 > o2 || o2 < k2 && l2 > C2) { 999 var E2 = i2.offsetWidth, A2 = i2.offsetHeight, L2 = o2 / A2, I2 = { width: E2 * L2, height: A2 * L2 }; 1000 i2.parentNode.setAttribute("style", "max-width: ".concat(I2.width, "px")), r2 && s2.setAttribute("style", "max-width: ".concat(I2.width, "px;")); 1001 } else 1002 i2.parentNode.style.maxWidth = "".concat(T2), r2 && s2.setAttribute("style", "max-width: ".concat(T2, ";")); 1003 } 1004 } 1005 } 1006 } }, { key: "reload", value: function() { 1007 this.init(); 1008 } }, { key: "updateNavigationClasses", value: function() { 1009 var e2 = this.loop(); 1010 c(this.nextButton, "disabled"), c(this.prevButton, "disabled"), 0 == this.index && this.elements.length - 1 == 0 ? (d(this.prevButton, "disabled"), d(this.nextButton, "disabled")) : 0 !== this.index || e2 ? this.index !== this.elements.length - 1 || e2 || d(this.nextButton, "disabled") : d(this.prevButton, "disabled"); 1011 } }, { key: "loop", value: function() { 1012 var e2 = P(this.settings, "loopAtEnd") ? this.settings.loopAtEnd : null; 1013 return e2 = P(this.settings, "loop") ? this.settings.loop : e2, e2; 1014 } }, { key: "close", value: function() { 1015 var e2 = this; 1016 if (!this.lightboxOpen) { 1017 if (this.events) { 1018 for (var t2 in this.events) 1019 this.events.hasOwnProperty(t2) && this.events[t2].destroy(); 1020 this.events = null; 1021 } 1022 return false; 1023 } 1024 if (this.closing) 1025 return false; 1026 this.closing = true, this.slidePlayerPause(this.activeSlide), this.fullElementsList && (this.elements = this.fullElementsList), this.bodyHiddenChildElms.length && r(this.bodyHiddenChildElms, function(e3) { 1027 e3.removeAttribute("aria-hidden"); 1028 }), d(this.modal, "glightbox-closing"), v(this.overlay, "none" == this.settings.openEffect ? "none" : this.settings.cssEfects.fade.out), v(this.activeSlide, this.settings.cssEfects[this.settings.closeEffect].out, function() { 1029 if (e2.activeSlide = null, e2.prevActiveSlideIndex = null, e2.prevActiveSlide = null, e2.built = false, e2.events) { 1030 for (var t3 in e2.events) 1031 e2.events.hasOwnProperty(t3) && e2.events[t3].destroy(); 1032 e2.events = null; 1033 } 1034 var i2 = document.body; 1035 c(ee, "glightbox-open"), c(i2, "glightbox-open touching gdesc-open glightbox-touch glightbox-mobile gscrollbar-fixer"), e2.modal.parentNode.removeChild(e2.modal), e2.trigger("close"), C(e2.settings.onClose) && e2.settings.onClose(); 1036 var n2 = document.querySelector(".gcss-styles"); 1037 n2 && n2.parentNode.removeChild(n2), e2.lightboxOpen = false, e2.closing = null; 1038 }); 1039 } }
1039, { key: "destroy", value: function() { 1040 this.close(), this.clearAllEvents(), this.baseEvents && this.baseEvents.destroy(); 1041 } }, { key: "on", value: function(e2, t2) { 1042 var i2 = arguments.length > 2 && void 0 !== arguments[2] && arguments[2]; 1043 if (!e2 || !C(t2)) 1044 throw new TypeError("Event name and callback must be defined"); 1045 this.apiEvents.push({ evt: e2, once: i2, callback: t2 }); 1046 } }, { key: "once", value: function(e2, t2) { 1047 this.on(e2, t2, true); 1048 } }, { key: "trigger", value: function(e2) { 1049 var t2 = this, i2 = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : null, n2 = []; 1050 r(this.apiEvents, function(t3, s2) { 1051 var l2 = t3.evt, o2 = t3.once, r2 = t3.callback; 1052 l2 == e2 && (r2(i2), o2 && n2.push(s2)); 1053 }), n2.length && r(n2, function(e3) { 1054 return t2.apiEvents.splice(e3, 1); 1055 }); 1056 } }, { key: "clearAllEvents", value: function() { 1057 this.apiEvents.splice(0, this.apiEvents.length); 1058 } }, { key: "version", value: function() { 1059 return "3.3.1"; 1060 } }]); 1061 return function() { 1062 var e2 = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, t2 = new ie(e2); 1063 return t2.init(), t2; 1064 }; 1065 }); 1066})(glightbox_min); 1067var glightbox_minExports = glightbox_min.exports; 1068const GLightbox = /* @__PURE__ */ getDefaultExportFromCjs(glightbox_minExports); 1069let _glightbox; 1070const glightBox = () => { 1071 if (_glightbox) 1072 return; 1073 _glightbox = GLightbox({ 1074 selector: "*[data-glightbox]", 1075 zoomable: false, 1076 openEffect: "fade", 1077 closeEffect: "fade" 1078 }); 1079 const originalOpen = _glightbox.open.bind(_glightbox); 1080 _glightbox.open = function(element, startAt) { 1081 if (element && element.nodeType === 1 && !element.getAttribute("data-gallery")) { 1082 const allElements = this.elements; 1083 this.fullElementsList = allElements; 1084 const parentModal = element.closest(".sd-modal"); 1085 if (parentModal) { 1086 this.elements = allElements.filter((el) => parentModal.contains(el.node)); 1087 } else { 1088 this.elements = allElements.filter((el) => el.node === element); 1089 } 1090 } 1091 return originalOpen(element, startAt); 1092 }; 1093}; 1094export { 1095 glightBox as g 1096}; 1097//# sourceMappingURL=glightbox.js.map
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.