vendor: 87 bytes, lines 1-4
1/******/ (() => { // webpackBootstrap 2/******/ var __webpack_modules__ = ({ 3 4/***/ "./
4resources/js/app.js": 5/*!*****************************!*\ 6 !*** ./resources/js/app.js ***! 7 \*****************************/ 8/***/ (() => { 9 10function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; } 11function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); } 12function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } 13function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } 14function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); } 15function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); } 16function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; } 17function forEach(htmlCollection, callback) { 18 for (var i = 0; i < htmlCollection.length; i++) { 19 callback(htmlCollection[i]); 20 } 21} 22function map(htmlCollection, callback) { 23 var out = []; 24 for (var i = 0; i < htmlCollection.length; i++) { 25 out.push(callback(htmlCollection[i])); 26 } 27 return out; 28} 29function getElementsArrayByClassName(container, className) { 30 return map(container.getElementsByClassName(className), function (i) { 31 return i; 32 }); 33} 34function getFirstElementByClassName(container, className) { 35 return getElementsArrayByClassName(container, className)[0]; 36} 37 38/** 39 * Moves the 0th element of the array to index `count`. 40 * 41 * Examples: 42 * > rotate(['a', 'b', 'c', 'd'], 2) 43 * [ "c", "d", "a", "b" ] 44 * 45 * > rotate(['a', 'b', 'c', 'd'], 1) 46 * [ "d", "a", "b", "c" ] 47 * 48 * > rotate(['a', 'b', 'c', 'd'], -1) 49 * [ "b", "c", "d", "a" ] 50 */ 51function rotate(arr, count) { 52 var out = _toConsumableArray(arr); 53 var len = out.length; 54 out.push.apply(out, _toConsumableArray(out.splice(0, (-count % len + len) % len))); 55 return out; 56} 57function setUpAircraftSlider() { 58 document.querySelectorAll('.js-aircraft').forEach(function (sliderContainer) { 59 var allAircraft = JSON.parse(sliderContainer.dataset.aircraft); 60 function shiftElements(shiftCount) { 61 function activeIndex() { 62 var activeAcfItem = sliderContainer.querySelector('.aircraft-item.active'); 63 var permalink = activeAcfItem.querySelector('.data-link').href; 64 return allAircraft.findIndex(function (item) { 65 return item.permalink === permalink; 66 }); 67 } 68 function replaceGuts(newAircraft) { 69 function replaceElementGuts(element, replaceWith) { 70 var nameEl = element.getElementsByClassName('data-name')[0]; 71 nameEl.innerHTML = replaceWith.title; 72 nameEl.href = replaceWith.permalink; 73 element.getElementsByClassName('data-icon')[0].src = replaceWith.thumb_url; 74 element.getElementsByClassName('data-description')[0].innerHTML = replaceWith.excerpt; 75 element.getElementsByClassName('data-link')[0].href = replaceWith.permalink; 76 } 77 var prevAcfItem = sliderContainer.querySelector('.aircraft-item.prev'); 78 var activeAcfItem = sliderContainer.querySelector('.aircraft-item.active'); 79 var nextAcfItem = sliderContainer.querySelector('.aircraft-item.next'); 80 replaceElementGuts(prevAcfItem, newAircraft[0]); 81 replaceElementGuts(activeAcfItem, newAircraft[1]); 82 replaceElementGuts(nextAcfItem, newAircraft[2]); 83 } 84 var prevActiveIdx = activeIndex(); 85 var newActiveIdx = prevActiveIdx + shiftCount; 86 var rotateBy = allAircraft.length - newActiveIdx + 1; 87 var newItems = rotate(allAircraft, rotateBy); 88 replaceGuts(newItems); 89 } 90 var _iterator = _createForOfIteratorHelper(sliderContainer.querySelectorAll('.btn-left')), 91 _step; 92 try { 93 for (_iterator.s();
93 !(_step = _iterator.n()).done;) { 94 var btn = _step.value; 95 btn.addEventListener('click', function () { 96 shiftElements(-1); 97 }); 98 } 99 } catch (err) { 100 _iterator.e(err); 101 } finally { 102 _iterator.f(); 103 } 104 var _iterator2 = _createForOfIteratorHelper(sliderContainer.getElementsByClassName('btn-right')), 105 _step2; 106 try { 107 for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) { 108 var _btn = _step2.value; 109 _btn.addEventListener('click', function () { 110 shiftElements(1); 111 }); 112 } 113 } catch (err) { 114 _iterator2.e(err); 115 } finally { 116 _iterator2.f(); 117 } 118 }); 119} 120function setUpSlickGalleries() { 121 document.querySelectorAll('.js-gallery').forEach(function (sliderContainer) { 122 sliderContainer.querySelectorAll('.slick-gallery').forEach(function (slickGallery) { 123 jQuery(slickGallery).slick(); 124 sliderContainer.querySelectorAll('.btn-left').forEach(function (btn) { 125 btn.addEventListener('click', function () { 126 jQuery(slickGallery).slick('slickPrev'); 127 }); 128 }); 129 sliderContainer.querySelectorAll('.btn-right').forEach(function (btn) { 130 btn.addEventListener('click', function () { 131 jQuery(slickGallery).slick('slickNext'); 132 }); 133 }); 134 }); 135 }); 136} 137function setUpGalleryLightboxes() { 138 var standaloneImages = document.querySelectorAll('.prose > .wp-block-image > img'); 139 forEach(standaloneImages, function (img) { 140 var lightboxWrapper = document.createElement('a'); 141 lightboxWrapper.setAttribute('href', img.src); 142 lightboxWrapper.appendChild(img.cloneNode(true)); 143 img.parentNode.replaceChild(lightboxWrapper, img); 144 }); 145 if (jQuery.hasOwnProperty('magnificPopup')) { 146 jQuery('.gallery a:not(.gallery-ignore), .wp-block-gallery a:not(.gallery-ignore), .wp-block-image a:not(.galleryIgnore), .slick-gallery a').magnificPopup({ 147 type: 'image', 148 closeOnContentClick: true, 149 gallery: { 150 enabled: true, 151 navigateByImgClick: false, 152 arrowMarkup: '<button title="%title%" type="button" class="mfp-arrow xp-mfp-arrow-%dir%"></button>' 153 } 154 }); 155 jQuery('.video-thumbnail a, a.video-modal-link').magnificPopup({ 156 type: 'iframe' 157 }); 158 } 159} 160function advanceSingle(sliderContainer, sign) { 161 var children = map(sliderContainer.children, function (i) { 162 return i; 163 }); 164 var activeIdx = children.findIndex(function (child) { 165 return !child.classList.contains('hidden'); 166 }); 167 var naiveNextIdx = activeIdx + sign * 1; 168 var nextIdx = naiveNextIdx < 0 ? children.length - 1 : naiveNextIdx >= children.length ? 0 : naiveNextIdx; 169 children[activeIdx].classList.add('hidden'); 170 children[nextIdx].classList.remove('hidden'); 171} 172function setUpSingleItemSlider() { 173 var sliderContainers = document.getElementsByClassName('js-slider-single-item');
174 forEach(sliderContainers, function (sliderContainer) { 175 forEach(sliderContainer.children, function (el) { 176 return el.classList.remove('first:block'); 177 }); 178 if (sliderContainer.childElementCount > 0) { 179 sliderContainer.children[0].classList.remove('hidden'); 180 } 181 forEach(sliderContainer.getElementsByClassName('btn-left'), function (btn) { 182 btn.addEventListener('click', function () { 183 advanceSingle(sliderContainer, -1); 184 }); 185 }); 186 forEach(sliderContainer.getElementsByClassName('btn-right'), function (btn) { 187 btn.addEventListener('click', function () { 188 advanceSingle(sliderContainer, 1); 189 }); 190 }); 191 }); 192} 193function toggleMoreProducts(toggleButton, toggleSection) { 194 var text = getFirstElementByClassName(toggleButton, 'text'); 195 var svg = getFirstElementByClassName(toggleButton, 'down-arrow'); 196 console.log("toggleSection", toggleSection); 197 console.log("toggleSection.dataset", toggleSection.dataset); 198 if (toggleSection.classList.contains('hidden')) { 199 text.innerHTML = toggleButton.dataset.showFewer; 200 svg.classList.add('flip'); 201 } else { 202 text.innerHTML = toggleButton.dataset.showMore; 203 svg.classList.remove('flip'); 204 } 205 toggleSection.classList.toggle('hidden'); 206} 207function setUpProductExpander() { 208 var toggles = document.getElementsByClassName('toggle-more-products'); 209 forEach(toggles, function (toggleBtn) { 210 var toggleSection = getFirstElementByClassName(toggleBtn.closest('section'), 'more-products'); 211 if (toggleSection) { 212 toggleBtn.addEventListener('click', function () { 213 return toggleMoreProducts(toggleBtn, toggleSection); 214 }); 215 } 216 }); 217} 218function setUpDownloadLinks() { 219 var links = document.getElementsByClassName('installer-link'); 220 forEach(links, function (link) { 221 var thanksUrl = link.dataset.thanksUrl; 222 var platform = link.dataset.platform; 223 if (thanksUrl && thanksUrl.length > 0 && platform && platform.length > 0) { 224 link.href = thanksUrl + "?downloadNow=true&os=" + platform + "&download_url=" + encodeURIComponent(link.href); 225 } 226 }); 227} 228function setUpAircraftMoreButton() { 229 document.querySelectorAll('button[data-show-more]').forEach(function (btn) { 230 var className = btn.dataset.showMore; 231 var itemsToToggle = document.querySelectorAll(".".concat(className)); 232 itemsToToggle.forEach(function (item) { 233 return item.classList.add('hidden'); 234 }); 235 btn.classList.remove('hidden'); 236 btn.addEventListener('click', function () { 237 if (itemsToToggle[0].classList.contains('hidden')) { 238 itemsToToggle.forEach(function (item) { 239 return item.classList.remove('hidden'); 240 }); 241 btn.textContent = "Hide more"; 242 } else { 243 itemsToToggle.forEach(function (item) { 244 return item.classList.add('hidden'); 245 }); 246 btn.textContent = "Show more"; 247 } 248 }); 249 }); 250} 251function setUpAnimatedGradientBackgrounds() { 252 var gradientBgSelector = '.xplane-animated-gradient-bg'; 253 if (document.querySelectorAll(gradientBgSelector).length > 0) { 254 var gradient = new Gradient(); 255 gradient.initGradient(gradientBgSelector); 256 } 257} 258function setup() { 259 var main_navigation = document.querySelector('#primary-menu'); 260 document.querySelector('#primary-menu-toggle').addEventListener('click', function (e) { 261 e.preventDefault(); 262 main_navigation.classList.toggle('hidden'); 263 }); 264 if (jQuery.hasOwnProperty('magnificPopup')) { 265 jQuery('.video-thumbnail a, a.video-modal-link').magnificPopup({ 266 type: 'iframe' 267 }); 268 } 269 setUpAircraftSlider(); 270 setUpSlickGalleries(); 271 setUpGalleryLightboxes(); 272 setUpSingleItemSlider(); 273 setUpProductExpander(); 274 setUpDownloadLinks(); 275 setUpAircraftMoreButton(); 276 setUpAnimatedGradientBackgrounds(); 277} 278 279// Navigation toggle 280window.addEventListener('DOMContentLoaded', setup); 281if (document.readyState !== "loading") { 282 setup(); 283} 284 285/***/ }), 286
287/***/ "./resources/css/app.css": 288/*!*******************************!*\ 289 !*** ./resources/css/app.css ***! 290 \*******************************/ 291/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { 292 293"use strict"; 294__webpack_require__.r(__webpack_exports__); 295// extracted by mini-css-extract-plugin 296 297 298/***/ }), 299
300/***/ "./resources/css/editor-style.css": 301/*!****************************************!*\ 302 !*** ./resources/css/editor-style.css ***! 303 \****************************************/ 304/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { 305 306"use strict"; 307__webpack_require__.r(__webpack_exports__); 308// extracted by mini-css-extract-plugin 309 310 311/***/ })
vendor: 6,147 bytes, lines 311-457
311 312 313/******/ }); 314/************************************************************************/ 315/******/ // The module cache 316/******/ var __webpack_module_cache__ = {}; 317/******/ 318/******/ // The require function 319/******/ function __webpack_require__(moduleId) { 320/******/ // Check if module is in cache 321/******/ var cachedModule = __webpack_module_cache__[moduleId]; 322/******/ if (cachedModule !== undefined) { 323/******/ return cachedModule.exports; 324/******/ } 325/******/ // Create a new module (and put it into the cache) 326/******/ var module = __webpack_module_cache__[moduleId] = { 327/******/ // no module.id needed 328/******/ // no module.loaded needed 329/******/ exports: {} 330/******/ }; 331/******/ 332/******/ // Execute the module function 333/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); 334/******/ 335/******/ // Return the exports of the module 336/******/ return module.exports; 337/******/ } 338/******/ 339/******/ // expose the modules object (__webpack_modules__) 340/******/ __webpack_require__.m = __webpack_modules__; 341/******/ 342/************************************************************************/ 343/******/ /* webpack/runtime/chunk loaded */ 344/******/ (() => { 345/******/ var deferred = []; 346/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { 347/******/ if(chunkIds) { 348/******/ priority = priority || 0; 349/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; 350/******/ deferred[i] = [chunkIds, fn, priority]; 351/******/ return; 352/******/ } 353/******/ var notFulfilled = Infinity; 354/******/ for (var i = 0; i < deferred.length; i++) { 355/******/ var [chunkIds, fn, priority] = deferred[i]; 356/******/ var fulfilled = true; 357/******/ for (var j = 0; j < chunkIds.length; j++) { 358/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { 359/******/ chunkIds.splice(j--, 1); 360/******/ } else { 361/******/ fulfilled = false; 362/******/ if(priority < notFulfilled) notFulfilled = priority; 363/******/ } 364/******/ } 365/******/ if(fulfilled) { 366/******/ deferred.splice(i--, 1) 367/******/ var r = fn(); 368/******/ if (r !== undefined) result = r; 369/******/ } 370/******/ } 371/******/ return result; 372/******/ }; 373/******/ })(); 374/******/ 375/******/ /* webpack/runtime/hasOwnProperty shorthand */ 376/******/ (() => { 377/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) 378/******/ })(); 379/******/ 380/******/ /* webpack/runtime/make namespace object */ 381/******/ (() => { 382/******/ // define __esModule on exports 383/******/ __webpack_require__.r = (exports) => { 384/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { 385/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); 386/******/ } 387/******/ Object.defineProperty(exports, '__esModule', { value: true }); 388/******/ }; 389/******/ })(); 390/******/ 391/******/ /* webpack/runtime/jsonp chunk loading */ 392/******/ (() => { 393/******/ // no baseURI 394/******/ 395/******/ // object to store loaded and loading chunks 396/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched 397/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded 398/******/ var installedChunks = { 399/******/ "/js/app": 0, 400/******/ "css/editor-style": 0, 401/******/ "css/app": 0 402/******/ }; 403/******/ 404/******/ // no chunk on demand loading 405/******/ 406/******/ // no prefetching 407/******/ 408/******/ // no preloaded 409/******/ 410/******/ // no HMR 411/******/ 412/******/ // no HMR manifest 413/******/ 414/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); 415/******/ 416/******/ // install a JSONP callback for chunk loading 417/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { 418/******/ var [chunkIds, moreModules, runtime] = data; 419/******/ // add "moreModules" to the modules object, 420/******/ // then flag all "chunkIds" as loaded and fire callback 421/******/ var moduleId, chunkId, i = 0; 422/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { 423/******/ for(moduleId in moreModules) { 424/******/ if(__webpack_require__.o(moreModules, moduleId)) { 425/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; 426/******/ } 427/******/ } 428/******/ if(runtime) var result = runtime(__webpack_require__); 429/******/ } 430/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); 431/******/ for(;i < chunkIds.length; i++) { 432/******/ chunkId = chunkIds[i]; 433/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { 434/******/ installedChunks[chunkId][0](); 435/******/ } 436/******/ installedChunks[chunkId] = 0; 437/******/ } 438/******/ return __webpack_require__.O(result); 439/******/ } 440/******/ 441/******/ var chunkLoadingGlobal = self["webpackChunkxplane2023"] = self["webpackChunkxplane2023"] || []; 442/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); 443/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); 444/******/ })(); 445/******/ 446/************************************************************************/ 447/******/ 448/******/ // startup 449/******/ // Load entry module and return exports 450/******/ // This entry module depends on other loaded chunks and execution need to be delayed 451/******/ __webpack_require__.O(undefined, ["css/editor-style","css/app"], () => (__webpack_require__("./resources/js/app.js"))) 452/******/ __webpack_require__.O(undefined, ["css/editor-style","css/app"], () => (__webpack_require__("./resources/css/app.css"))) 453/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["css/editor-style","css/app"], () => (__webpack_require__("./resources/css/editor-style.css"))) 454/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); 455/******/ 456/******/ })() 457;
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.