芝麻web文件管理V1.00
编辑当前文件:/home/pulsehostuk9/www/misfits2/wp-content/plugins/uicore-framework/assets/js/frontend.js
/* * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development"). * This devtool is neither made for production nor for readable output files. * It uses "eval()" calls to create a separate source file in the browser devtools. * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/) * or disable the default devtool with "devtool: false". * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/). */ /******/ (() => { // webpackBootstrap /******/ var __webpack_modules__ = ({ /***/ "./assets/src/frontend/all.js": /*!************************************!*\ !*** ./assets/src/frontend/all.js ***! \************************************/ /***/ (() => { eval("document.addEventListener('DOMContentLoaded', function () {\n if (document.querySelector('.uicore-sticky') || document.querySelector('.uicore-will-be-sticky')) {\n // console.log('sticky');\n // Debounce the uiCoreOnScroll function so it is not called too frequently\n var uiDebounce = function uiDebounce(func, wait) {\n var timeout;\n return function () {\n var context = this,\n args = arguments;\n var later = function later() {\n timeout = null;\n func.apply(context, args);\n };\n clearTimeout(timeout);\n timeout = setTimeout(later, wait);\n };\n };\n var uiCoreOnScroll = function uiCoreOnScroll() {\n // console.log('scrolling');\n var mq = window.matchMedia(\"(max-width: 1025px)\");\n var isMobile = mq.matches;\n var winTop = window.scrollY || window.pageYOffset;\n var topBar = document.querySelector('.uicore-top-bar');\n var h = topBar ? topBar.offsetHeight : null;\n var defaultH = 120;\n if (document.querySelector('.uicore-transparent .ui-header-row1')) {\n defaultH = 19;\n } else if (document.querySelector('.ui-header-row1')) {\n defaultH = 400;\n }\n if (h == null) h = isMobile ? 25 : defaultH;\n\n //scrolled\n // console.log(winTop,h);\n\n if (winTop > h) {\n setTimeout(function () {\n document.querySelectorAll('.uicore-navbar').forEach(function (el) {\n el.classList.add('uicore-scrolled');\n });\n }, 10);\n } else {\n document.querySelectorAll('.uicore-navbar').forEach(function (el) {\n el.classList.remove('uicore-scrolled');\n });\n }\n\n //scroll direction\n if (winTop > lastScrollTop && lastScrollTop > 0 && winTop > h - 85 / 100 * h) {\n document.querySelectorAll('.ui-smart-sticky').forEach(function (el) {\n el.classList.add('ui-hide');\n });\n } else {\n document.querySelectorAll('.ui-smart-sticky').forEach(function (el) {\n el.classList.remove('ui-hide');\n });\n }\n\n //show menu at scroll to bottom\n if (winTop + window.innerHeight > document.documentElement.scrollHeight - 50) {\n document.querySelectorAll('.ui-smart-sticky').forEach(function (el) {\n el.classList.remove('ui-hide');\n });\n }\n lastScrollTop = winTop;\n }; //Trigger on load and on scroll\n var lastScrollTop = 0;\n uiCoreOnScroll();\n\n // Debounce the uiCoreOnScroll function so it is not called too frequently\n var debouncedUiCoreOnScroll = uiDebounce(uiCoreOnScroll, 500);\n window.addEventListener('scroll', uiCoreOnScroll);\n document.body.addEventListener('touchmove', debouncedUiCoreOnScroll);\n }\n});\n\n// Windows class on body\nif (navigator.appVersion.indexOf('Win') != -1) {\n document.body.classList.add('win');\n}\n\n// Search button and close\ndocument.addEventListener('DOMContentLoaded', function () {\n document.querySelectorAll('.uicore-search-btn').forEach(function (btn) {\n btn.addEventListener('click', function () {\n document.body.classList.add('uicore-search-active');\n var searchField = document.querySelector('.uicore-search .search-field');\n if (searchField) searchField.focus();\n });\n });\n document.querySelectorAll('.uicore-search .uicore-close').forEach(function (btn) {\n btn.addEventListener('click', function () {\n document.body.classList.remove('uicore-search-active');\n });\n });\n document.addEventListener('keydown', function (e) {\n if (e.keyCode === 27) {\n document.body.classList.remove('uicore-search-active');\n }\n });\n document.querySelectorAll('.uicore-h-classic .menu-item-has-children:not(.menu-item-has-megamenu.custom-width)').forEach(function (item) {\n item.addEventListener('mouseenter', function (e) {\n if (item.querySelector('ul')) {\n var elm = item.querySelector('.sub-menu');\n if (!elm) return;\n var off = elm.getBoundingClientRect();\n var l = off.left + window.scrollX;\n var w = elm.offsetWidth;\n var docW = document.body.offsetWidth;\n if (l + w > docW) {\n item.classList.add('uicore-edge');\n }\n }\n });\n item.addEventListener('mouseleave', function (e) {\n item.classList.remove('uicore-edge');\n });\n });\n\n // Back to top\n var btn = document.getElementById('uicore-back-to-top');\n if (btn) {\n window.addEventListener('scroll', function () {\n if (window.scrollY > 300) {\n btn.classList.add('uicore-visible');\n } else {\n btn.classList.remove('uicore-visible');\n }\n });\n btn.addEventListener('click', function (e) {\n e.preventDefault();\n window.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n });\n }\n});\n\n// Progress bar\ndocument.addEventListener('DOMContentLoaded', function () {\n if (document.querySelector('.uicore-progress-bar')) {\n var getMax = function getMax() {\n var value = document.body.scrollHeight - window.innerHeight;\n var postContainer = document.querySelector('.uicore-post-content article');\n if (postContainer) {\n value = postContainer.offsetHeight + postContainer.getBoundingClientRect().top + window.scrollY - window.innerHeight;\n }\n return value;\n };\n var getValue = function getValue() {\n return window.scrollY || window.pageYOffset;\n };\n var progressBar = document.querySelector('.uicore-progress-bar'),\n max = getMax(),\n value,\n width;\n var getWidth = function getWidth() {\n value = getValue();\n width = value / max * 100;\n if (width > 100) {\n width = 100;\n }\n width = width + '%';\n return width;\n };\n var setWidth = function setWidth() {\n if (progressBar) progressBar.style.width = getWidth();\n };\n window.addEventListener('scroll', setWidth);\n window.addEventListener('resize', function () {\n max = getMax();\n setWidth();\n });\n }\n});\n\n// Megamenu custom width\ndocument.addEventListener('DOMContentLoaded', function () {\n var menuItems = document.querySelectorAll('.menu-item-has-megamenu.custom-width');\n var setOffset = function setOffset(li) {\n var mq = window.matchMedia(\"(max-width: 1025px)\");\n var isMobile = mq.matches;\n var dropdown = li.querySelector('ul.uicore-megamenu');\n\n //reset\n if (dropdown) dropdown.style.left = 'auto';\n if (!isMobile && dropdown) {\n dropdown.style.left = '0px';\n var dropdownWidth = dropdown.offsetWidth,\n dropdownRect = dropdown.getBoundingClientRect(),\n dropdownOffset = {\n left: dropdownRect.left + window.scrollX\n },\n viewportWidth = window.innerWidth,\n extraSpace = 0;\n if (!dropdownWidth || !dropdownOffset) return;\n if (dropdownOffset.left + dropdownWidth >= viewportWidth) {\n // If right point is not in the viewport\n var toRight = dropdownOffset.left + dropdownWidth - viewportWidth;\n dropdown.style.left = -toRight - extraSpace + 'px';\n }\n }\n };\n menuItems.forEach(function (li) {\n li.addEventListener('mouseenter', function (e) {\n setOffset(li);\n });\n li.addEventListener('mouseleave', function (e) {\n setOffset(li);\n });\n setOffset(li);\n li.classList.add('with-offsets');\n });\n});\n\n//# sourceURL=webpack://uicore-framework/./assets/src/frontend/all.js?"); /***/ }), /***/ "./assets/src/frontend/main.js": /*!*************************************!*\ !*** ./assets/src/frontend/main.js ***! \*************************************/ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { "use strict"; eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _frontend_scss_style_scss__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @/frontend/scss/style.scss */ \"./assets/src/frontend/scss/style.scss\");\n/* harmony import */ var _frontend_all__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/frontend/all */ \"./assets/src/frontend/all.js\");\n/* harmony import */ var _frontend_all__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_frontend_all__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _frontend_mobileHeader__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/frontend/mobileHeader */ \"./assets/src/frontend/mobileHeader.js\");\n/* harmony import */ var _frontend_mobileHeader__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_frontend_mobileHeader__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _frontend_themeBuilder__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/frontend/themeBuilder */ \"./assets/src/frontend/themeBuilder.js\");\n/* harmony import */ var _frontend_themeBuilder__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_frontend_themeBuilder__WEBPACK_IMPORTED_MODULE_3__);\n\n\n\n\n\n//# sourceURL=webpack://uicore-framework/./assets/src/frontend/main.js?"); /***/ }), /***/ "./assets/src/frontend/mobileHeader.js": /*!*********************************************!*\ !*** ./assets/src/frontend/mobileHeader.js ***! \*********************************************/ /***/ (() => { eval("/////////////////////////////////////////////////////////// Mobile Menu\ndocument.addEventListener('DOMContentLoaded', function () {\n var mq = window.matchMedia(\"(max-width: \" + window.uicore_frontend.mobile_br + \"px)\");\n var isMobile = mq.matches;\n //Init on load\n initMobileOrHam();\n //Init on Window resize\n window.onresize = initMobileOrHam;\n\n // Helper functions for vanilla JS event binding/unbinding\n function addEvent(selector, event, handler) {\n document.querySelectorAll(selector).forEach(function (el) {\n el.addEventListener(event, handler);\n });\n }\n function removeEvent(selector, event, handler) {\n document.querySelectorAll(selector).forEach(function (el) {\n el.removeEventListener(event, handler);\n });\n }\n\n // Helper for closest parent with selector\n function closest(el, selector) {\n while (el && el.nodeType === 1) {\n if (el.matches(selector)) return el;\n el = el.parentElement;\n }\n return null;\n }\n\n // Helper for fadeTo (simple opacity animation)\n function fadeTo(el, duration, opacity) {\n el.style.transition = \"opacity \" + duration + \"ms\";\n el.style.opacity = opacity;\n }\n\n //Main\n function initMobileOrHam() {\n //Let's start by unbinding all\n removeEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a', 'click', mobileSubmenuOpen);\n removeEvent('.uicore-mobile-menu-wrapper .uicore-menu-container .sub-menu .back > a', 'click', mobileSubmenuClose);\n removeEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a:not(.ui-custom-tap)', 'click', mobileSubmenuExpand);\n // removeEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a:not(.ui-custom-tap) span', 'click', mobileSubmenuExpand)\n removeEvent('.uicore-mobile-menu-wrapper li:not(.menu-item-has-children):not(.back) > a', 'click', menuToggle);\n removeEvent('.uicore-mobile-menu-wrapper .uicore-extra a', 'click', menuToggle);\n removeEvent('.uicore-mobile-menu-wrapper.uicore-ham-classic .menu-item-has-children', 'mouseenter', hamClassicSubmenuOpen);\n removeEvent('.uicore-mobile-menu-wrapper.uicore-ham-classic .menu-item-has-children', 'mouseleave', hamClassicSubmenuClose);\n removeEvent('.uicore-mobile-menu-wrapper.uicore-ham-center .menu-item-has-children a, .uicore-mobile-menu-wrapper.uicore-ham-creative .menu-item-has-children a', 'click', hamSubmenuToggle);\n removeEvent('.uicore-menu-focus .uicore-menu li', 'mouseenter', menuFocusIn);\n removeEvent('.uicore-menu-focus .uicore-menu li', 'mouseleave', menuFocusOut);\n\n //BIND EVENTS\n if (isMobile) {\n //slide effect\n if (document.body.classList.contains('ui-a-dsmm-slide')) {\n addBackLink();\n // Mobile Submenu\n addEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a:not(.ui-custom-tap)', 'click', mobileSubmenuOpen);\n addEvent('.uicore-mobile-menu-wrapper .uicore-menu-container .sub-menu .back > a', 'click', mobileSubmenuClose);\n } else {\n addEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a:not(.ui-custom-tap)', 'click', mobileSubmenuExpand);\n // addEvent('.uicore-mobile-menu-wrapper .menu-item-has-children > a:not(.ui-custom-tap) span', 'click', mobileSubmenuExpand)\n }\n } else {\n // Desktop Ham Menu Classic\n addEvent('.uicore-mobile-menu-wrapper.uicore-ham-classic .menu-item-has-children', 'mouseenter', hamClassicSubmenuOpen);\n addEvent('.uicore-mobile-menu-wrapper.uicore-ham-classic .menu-item-has-children', 'mouseleave', hamClassicSubmenuClose);\n // Desktop Ham Menu Other\n addEvent('.uicore-mobile-menu-wrapper.uicore-ham-center .menu-item-has-children > a, .uicore-mobile-menu-wrapper.uicore-ham-creative .menu-item-has-children > a', 'click', hamSubmenuToggle);\n // Desktop Ham Menu Triggers\n addEvent('.uicore-mobile-menu-wrapper.uicore-ham-center .menu-item-has-children > a, .uicore-mobile-menu-wrapper.uicore-ham-creative .menu-item-has-children > a', 'click', hamMenuClick);\n\n //MENU FOCUS\n addEvent('.uicore-menu-focus .uicore-menu li', 'mouseenter', menuFocusIn);\n addEvent('.uicore-menu-focus .uicore-menu li', 'mouseleave', menuFocusOut);\n }\n //Close Menu on link click (mobile + desktop ham)\n addEvent('.uicore-mobile-menu-wrapper li:not(.menu-item-has-children):not(.back) > a', 'click', menuToggle);\n addEvent('.uicore-mobile-menu-wrapper .uicore-extra a', 'click', menuToggle);\n }\n document.querySelectorAll('.uicore-toggle').forEach(function (el) {\n el.addEventListener('click', menuToggle);\n });\n function addSubmenuParentClick(menuItem) {\n var items = menuItem || document.querySelectorAll('.uicore-mobile-menu-wrapper .uicore-menu-container .menu-item-has-children');\n items = items instanceof NodeList ? Array.from(items) : Array.isArray(items) ? items : [items];\n items.forEach(function (item) {\n var a = item.querySelector(':scope > a');\n var url = a ? a.getAttribute('href') : null;\n // Remove existing .ui-custom-tap children\n var customTaps = item.querySelectorAll('.ui-custom-tap');\n customTaps.forEach(function (tap) {\n tap.remove();\n });\n if (url && url !== '#') {\n var newA = document.createElement('a');\n newA.href = url;\n newA.textContent = \"\";\n newA.className = \"ui-custom-tap\";\n newA.style.minHeight = item.offsetHeight + \"px\";\n newA.style.transform = \"translate3d(0,-\" + item.offsetHeight + \"px,0)\";\n // Insert after the first
\n if (a && a.nextSibling) {\n item.insertBefore(newA, a.nextSibling);\n } else if (a) {\n item.appendChild(newA);\n }\n }\n });\n }\n function addBackLink() {\n if (!window.uicoreBackLinks) {\n var hasChildren = document.querySelectorAll('.menu-item-has-children');\n for (var i = 0; i < hasChildren.length; i++) {\n var backWord = uicore_frontend.back;\n if (!backWord) {\n //get the title of the parent\n backWord = hasChildren[i].children[0].innerText;\n }\n var element = hasChildren[i];\n var a = document.createElement('a');\n a.href = '#';\n a.textContent = backWord;\n var li = document.createElement('li');\n li.className = 'menu-item back';\n li.appendChild(a);\n // Prepend to the submenu (element.children[1])\n if (element.children[1]) {\n element.children[1].insertBefore(li, element.children[1].firstChild);\n }\n }\n window.uicoreBackLinks = true;\n }\n }\n function mobileSubmenuExpand(e) {\n e.preventDefault();\n // close other expanded items ( only if they are on the same level )\n if (window.closeOtherSubMenus) {\n var parent = this.parentElement;\n var siblings = Array.from(parent.parentElement.children).filter(function (child) {\n return child !== parent;\n });\n siblings.forEach(function (sib) {\n sib.classList.remove('ui-expanded');\n var subMenu = sib.querySelector('.sub-menu');\n if (subMenu) {\n subMenu.style.display = 'none';\n }\n });\n }\n // open current item\n var subMenu = this.parentElement.querySelector('.sub-menu');\n if (subMenu) {\n if (subMenu.style.display === 'block') {\n subMenu.style.display = 'none';\n } else {\n subMenu.style.display = 'block';\n }\n }\n this.classList.toggle('ui-expanded');\n Array.from(this.parentElement.children).forEach(function (child) {\n if (child !== this) child.classList.toggle('uicore-active');\n }, this);\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n fadeItem();\n }\n function mobileSubmenuOpen(e) {\n e.preventDefault();\n var leftMove = '';\n // Add class to all .uicore-mobile-menu-wrapper .uicore-menu\n document.querySelectorAll('.uicore-mobile-menu-wrapper .uicore-menu').forEach(function (menu) {\n menu.classList.add('uicore-animating');\n });\n // Add class to siblings\n Array.from(this.parentElement.children).forEach(function (child) {\n if (child !== this) child.classList.add('uicore-active');\n }, this);\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n var menu = document.querySelector('.uicore-mobile-menu-wrapper .uicore-menu-container .uicore-menu');\n var left = menu ? menu.style.left : '';\n if (left == '0' || left == '0%' || left == '') {\n leftMove = '-100%';\n } else {\n left = left.replace('-', '').replace('%', '');\n leftMove = '-' + (parseInt(left) + 100) + '%';\n }\n if (uicore_frontend.rtl === '1') {\n leftMove = leftMove.replace('-', '+');\n }\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n setTimeout(function () {\n if (menu) {\n menu.style.transition = 'left 150ms';\n menu.style.left = leftMove;\n setTimeout(function () {\n fadeItem();\n menu.classList.remove('uicore-animating');\n }, 150);\n }\n }, 100);\n }\n function mobileSubmenuClose(e) {\n e.preventDefault();\n var leftMove = '';\n // Add class to all .uicore-mobile-menu-wrapper .uicore-menu\n document.querySelectorAll('.uicore-mobile-menu-wrapper .uicore-menu-container .uicore-menu').forEach(function (menu) {\n menu.classList.add('uicore-animating');\n });\n var menu = document.querySelector('.uicore-mobile-menu-wrapper .uicore-menu-container .uicore-menu');\n var left = menu ? menu.style.left : '';\n if (left == '-100%' || left == '0%' || left == '' || left == '+100%' || left == '100%') {\n leftMove = '0%';\n } else {\n left = left.replace('-', '').replace('%', '');\n leftMove = '-' + (parseInt(left) - 100) + '%';\n }\n if (uicore_frontend.rtl === '1') {\n leftMove = leftMove.replace('-', '+');\n }\n var _this = this;\n setTimeout(function () {\n // Remove class from grandparent\n var parent = _this.parentElement;\n if (parent && parent.parentElement) {\n parent.parentElement.classList.remove('uicore-active');\n }\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n }, 300);\n setTimeout(function () {\n if (menu) {\n menu.style.transition = 'left 150ms';\n menu.style.left = leftMove;\n setTimeout(function () {\n document.querySelectorAll('.uicore-mobile-menu-wrapper .uicore-menu .sub-menu:not(.uicore-active) li').forEach(function (li) {\n li.classList.remove('uicore-visible');\n });\n fadeItem();\n menu.classList.remove('uicore-animating');\n }, 150);\n }\n }, 100);\n }\n function hamClassicSubmenuOpen(e) {\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n // Find first .sub-menu and add class\n var subMenu = this.querySelector('.sub-menu');\n if (subMenu) subMenu.classList.add('uicore-active');\n fadeItem();\n }\n function hamClassicSubmenuClose(e) {\n // Remove class from last .sub-menu child\n var subMenus = this.querySelectorAll('.sub-menu');\n if (subMenus.length) {\n subMenus[subMenus.length - 1].classList.remove('uicore-active');\n }\n // Remove class from all li descendants\n this.querySelectorAll('li').forEach(function (li) {\n li.classList.remove('uicore-visible');\n });\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n }\n function hamSubmenuToggle(e) {\n var parent = this.parentElement;\n var subMenu = parent.querySelector('.sub-menu');\n if (subMenu) {\n subMenu.classList.toggle('uicore-active');\n // Simple slideToggle effect\n if (subMenu.style.display === 'block') {\n subMenu.style.display = 'none';\n } else {\n subMenu.style.display = 'block';\n }\n if (subMenu.classList.contains('uicore-active')) {\n fadeItem();\n } else {\n parent.querySelectorAll('li').forEach(function (li) {\n li.classList.remove('uicore-visible');\n });\n }\n }\n }\n function hamMenuClick(e) {\n e.preventDefault();\n var regex = /^#.+$/;\n var href = this.getAttribute('href');\n if (regex.test(href)) {\n if (document.body.classList.contains('uicore-overflow-hidden')) {\n document.querySelectorAll('.uicore-mobile-menu-overflow').forEach(function (el) {\n el.classList.remove('uicore-overflow-hidden');\n });\n document.body.classList.remove('uicore-overflow-hidden');\n document.body.classList.remove('uicore-mobile-nav-show');\n if (isMobile) {\n if (document.querySelector('.uicore-animate-fade')) {\n document.querySelectorAll('.uicore-navigation-wrapper').forEach(function (nav) {\n nav.style.transition = 'opacity 100ms';\n nav.style.opacity = 0;\n });\n } else {\n setTimeout(function () {\n document.querySelectorAll('.uicore-navigation-wrapper').forEach(function (nav) {\n nav.style.transition = 'opacity 50ms';\n nav.style.opacity = 0;\n });\n }, 50);\n }\n } else {\n document.querySelectorAll('.uicore-navigation-wrapper').forEach(function (nav) {\n nav.style.transition = 'opacity 100ms';\n nav.style.opacity = 0;\n });\n }\n window.location.href = href;\n }\n }\n }\n function menuFocusIn() {\n // Mouse over\n var siblings = Array.from(this.parentNode.children).filter(function (el) {\n return el !== this;\n }, this);\n siblings.forEach(function (el) {\n fadeTo(el, 300, 0.4);\n });\n var parentSiblings = Array.from(this.parentNode.parentNode.children).filter(function (el) {\n return el !== this.parentNode;\n }, this);\n parentSiblings.forEach(function (el) {\n fadeTo(el, 300, 0.3);\n });\n }\n function menuFocusOut() {\n // Mouse out\n var siblings = Array.from(this.parentNode.children).filter(function (el) {\n return el !== this;\n }, this);\n siblings.forEach(function (el) {\n fadeTo(el, 300, 1);\n });\n var parentSiblings = Array.from(this.parentNode.parentNode.children).filter(function (el) {\n return el !== this.parentNode;\n }, this);\n parentSiblings.forEach(function (el) {\n fadeTo(el, 300, 1);\n });\n }\n\n // Cache elements for performance\n var uicoreReveal = document.querySelectorAll('.uicore-ham-reveal');\n var uicoreMobileMenu = document.querySelector('.uicore-mobile-menu-wrapper .uicore-menu-container .uicore-menu');\n var uicoreNavWrapper = document.querySelector('.uicore-navigation-wrapper');\n var uicoreMobileMenuOverflow = document.querySelectorAll('.uicore-mobile-menu-overflow');\n var uicoreMenuContainers = document.querySelectorAll('.uicore-mobile-menu-wrapper .uicore-menu-container');\n var uicoreMenuWrapperLis = document.querySelectorAll('.uicore-mobile-menu-wrapper li');\n var uicoreHamReveal = document.querySelectorAll('.uicore-ham-reveal');\n function menuToggle(e) {\n if (window.uicoreAnimation) {\n return;\n }\n window.uicoreAnimation = true;\n\n // Continue only if is not link click or if is link and points to current page\n var url = this.getAttribute('href');\n if (url) {\n var urlData = url.split('#');\n if (urlData[0] && urlData[0] != window.location.pathname && urlData[0] != window.location.href.split('#')[0]) {\n // Will navigate away from the page so we don't have to close the menu\n return;\n }\n }\n uicoreMobileMenu.classList.toggle('uicore-active');\n\n // HIDE\n if (document.body.classList.contains('uicore-overflow-hidden')) {\n if (typeof window.uicoreBeforeMobileMenuHide === 'function') {\n window.uicoreBeforeMobileMenuHide();\n }\n uicoreMobileMenuOverflow.forEach(function (el) {\n el.classList.remove('uicore-overflow-hidden');\n });\n document.body.classList.remove('uicore-overflow-hidden');\n document.documentElement.classList.remove('uicore-overflow-hidden');\n document.body.classList.remove('uicore-mobile-nav-show');\n\n // on fade hide it without any delay\n if (isMobile) {\n if (document.querySelector('.uicore-animate-fade')) {\n requestAnimationFrame(function () {\n uicoreNavWrapper.style.transition = 'opacity 100ms';\n uicoreNavWrapper.style.opacity = 0;\n });\n } else {\n setTimeout(function () {\n requestAnimationFrame(function () {\n uicoreNavWrapper.style.transition = 'opacity 50ms';\n uicoreNavWrapper.style.opacity = 0;\n });\n }, 50);\n }\n } else {\n requestAnimationFrame(function () {\n uicoreNavWrapper.style.transition = 'opacity 100ms';\n uicoreNavWrapper.style.opacity = 0;\n });\n }\n // reset animation\n uicoreMenuWrapperLis.forEach(function (el) {\n el.classList.remove('uicore-visible');\n });\n uicoreHamReveal.forEach(function (el) {\n el.style.animationName = 'none';\n });\n\n // SHOW\n } else {\n if (typeof window.uicoreBeforeMobileMenuShow === 'function') {\n window.uicoreBeforeMobileMenuShow();\n }\n var time = 0;\n\n // reveal\n if (uicoreReveal.length) {\n if (!isMobile) {\n uicoreReveal.forEach(function (el) {\n requestAnimationFrame(function () {\n el.style.animationName = 'uiCoreAnimationsHamReveal';\n });\n });\n time = 100;\n }\n setTimeout(function () {\n requestAnimationFrame(function () {\n uicoreNavWrapper.style.opacity = 1;\n });\n }, 0 + time);\n\n // fade\n } else {\n time = 20;\n setTimeout(function () {\n requestAnimationFrame(function () {\n uicoreNavWrapper.style.transition = 'opacity 100ms';\n uicoreNavWrapper.style.opacity = 1;\n });\n }, time);\n }\n document.body.classList.add('uicore-overflow-hidden');\n document.documentElement.classList.add('uicore-overflow-hidden');\n document.body.classList.add('uicore-mobile-nav-show');\n setTimeout(function () {\n uicoreMobileMenuOverflow.forEach(function (el) {\n el.classList.add('uicore-overflow-hidden');\n });\n uicoreMenuContainers.forEach(function (el) {\n requestAnimationFrame(function () {\n el.style.left = '0%';\n });\n });\n fadeItem();\n }, time);\n }\n this.classList.toggle('collapsed');\n setTimeout(function () {\n window.uicoreAnimation = false;\n }, 50);\n }\n\n // -- menu item fade in up\n function fadeItem() {\n // Select all first-level, not-yet-visible menu items inside an active menu\n var menuItems = document.querySelectorAll('ul.uicore-active > li:not(.uicore-visible)');\n if (menuItems.length) {\n menuItems.forEach(function (menuItem, idx) {\n setTimeout(function () {\n menuItem.classList.add('uicore-visible');\n if (menuItem.classList.contains('menu-item-has-children')) {\n addSubmenuParentClick(menuItem);\n }\n }, idx * 50); // stagger the animation\n });\n }\n }\n});\n\n//# sourceURL=webpack://uicore-framework/./assets/src/frontend/mobileHeader.js?"); /***/ }), /***/ "./assets/src/frontend/scss/style.scss": /*!*********************************************!*\ !*** ./assets/src/frontend/scss/style.scss ***! \*********************************************/ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { "use strict"; eval("__webpack_require__.r(__webpack_exports__);\n// extracted by mini-css-extract-plugin\n\n\n//# sourceURL=webpack://uicore-framework/./assets/src/frontend/scss/style.scss?"); /***/ }), /***/ "./assets/src/frontend/themeBuilder.js": /*!*********************************************!*\ !*** ./assets/src/frontend/themeBuilder.js ***! \*********************************************/ /***/ (() => { eval("document.addEventListener('DOMContentLoaded', function () {\n //Theme Builder animation retrigger\n document.querySelectorAll(\".menu-item-object-uicore-tb\").forEach(function (menuItem) {\n ['mouseenter', 'mouseleave'].forEach(function (eventName) {\n menuItem.addEventListener(eventName, function () {\n menuItem.querySelectorAll(\".elementor-element\").forEach(function (el) {\n elementorFrontend.elementsHandler.runReadyTrigger(el);\n });\n });\n });\n });\n});\n\n//# sourceURL=webpack://uicore-framework/./assets/src/frontend/themeBuilder.js?"); /***/ }) /******/ }); /************************************************************************/ /******/ // The module cache /******/ var __webpack_module_cache__ = {}; /******/ /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ // Check if module is in cache /******/ var cachedModule = __webpack_module_cache__[moduleId]; /******/ if (cachedModule !== undefined) { /******/ return cachedModule.exports; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = __webpack_module_cache__[moduleId] = { /******/ // no module.id needed /******/ // no module.loaded needed /******/ exports: {} /******/ }; /******/ /******/ // Execute the module function /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); /******/ /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ /************************************************************************/ /******/ /* webpack/runtime/compat get default export */ /******/ (() => { /******/ // getDefaultExport function for compatibility with non-harmony modules /******/ __webpack_require__.n = (module) => { /******/ var getter = module && module.__esModule ? /******/ () => (module['default']) : /******/ () => (module); /******/ __webpack_require__.d(getter, { a: getter }); /******/ return getter; /******/ }; /******/ })(); /******/ /******/ /* webpack/runtime/define property getters */ /******/ (() => { /******/ // define getter functions for harmony exports /******/ __webpack_require__.d = (exports, definition) => { /******/ for(var key in definition) { /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); /******/ } /******/ } /******/ }; /******/ })(); /******/ /******/ /* webpack/runtime/hasOwnProperty shorthand */ /******/ (() => { /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) /******/ })(); /******/ /******/ /* webpack/runtime/make namespace object */ /******/ (() => { /******/ // define __esModule on exports /******/ __webpack_require__.r = (exports) => { /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); /******/ } /******/ Object.defineProperty(exports, '__esModule', { value: true }); /******/ }; /******/ })(); /******/ /************************************************************************/ /******/ /******/ // startup /******/ // Load entry module and return exports /******/ // This entry module can't be inlined because the eval devtool is used. /******/ var __webpack_exports__ = __webpack_require__("./assets/src/frontend/main.js"); /******/ /******/ })() ;