(window["webpackJsonp_name_"] = window["webpackJsonp_name_"] || []).push([[89,87],{ /***/ 52: /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } /** * Lumeric global variables * ww - window.innerWidth * wh - window.innerHeight */ var GlobalVariables = function () { function GlobalVariables() { _classCallCheck(this, GlobalVariables); this.windowIsLoad = false; this.scrollWidth = 0; this.ww = window.innerWidth; this.wh = window.innerHeight; this.scrollBox = document; this.arr = []; this.lumericMain = document.querySelector('.wpw'); this.main = this.mainWrapper = document.querySelector('.main'); this.navRightIn = document.querySelector('.main__wrapper > .aside-right'); this.navLeftIn = document.querySelector('.main__wrapper > .aside-left'); if (this.main) { this.windowIsLoad = false; // this.setScrollWidth(); this.setScrollWidth(); // set layout size this.setLayout(); this.main.ontouchstart = function (event) { event.stopPropagation(); }; } } _createClass(GlobalVariables, [{ key: 'setLayout', value: function setLayout() { this.setLayoutMainWrapper(); return false; } }, { key: 'setLayoutMainWrapper', value: function setLayoutMainWrapper() { if (window.navbars && Object.keys(window.navbars).length) { var leftWidth = Object.keys(window.navbars).some(function (key) { return window.navbars[key]['navbar_type'] === "left" && window.navbars[key].options['in_out'] === 'in'; }) ? this.navLeftIn && this.navLeftIn.clientWidth : 0; var rightWidth = Object.keys(window.navbars).some(function (key) { return window.navbars[key]['navbar_type'] === "right" && window.navbars[key].options['in_out'] === 'in'; }) ? this.navRightIn && this.navRightIn.clientWidth : 0; if (leftWidth || rightWidth) { this.mainWrapper.style.cssText = 'padding-left: ' + leftWidth + 'px; padding-right: ' + rightWidth + 'px;'; } } } /** * Set scroll width * Need for scroll style */ }, { key: 'setScrollWidth', value: function setScrollWidth() { if (document.body.classList.contains('wpw-custom-scroll')) { var outer = document.createElement('div'); outer.className = 'scroll-tmp-div'; outer.style.visibility = 'hidden'; outer.style.width = '100px'; outer.style.msOverflowStyle = 'scrollbar'; // needed for WinJS apps // document.body.appendChild(outer); var widthNoScroll = outer.offsetWidth; // force scroll bars outer.style.overflow = 'scroll'; // add inner div var inner = document.createElement('div'); inner.style.width = '100%'; outer.appendChild(inner); var widthWithScroll = inner.offsetWidth; // remove divs outer.parentNode && outer.parentNode.removeChild(outer); this.scrollWidth = widthNoScroll - widthWithScroll; } else { this.scrollWidth = 17; } } /** * On window resize */ }, { key: 'resize', value: function resize() { this.ww = window.innerWidth; this.wh = window.innerHeight; // this.mainClientWidth = this.main.clientWidth; this.setScrollWidth(); // reset layout size this.setLayout(); } }]); return GlobalVariables; }(); exports.default = new GlobalVariables(); /***/ }), /***/ 84: /***/ (function(module, exports, __webpack_require__) { "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.postHeaderHeight = postHeaderHeight; var _global = __webpack_require__(52); var _global2 = _interopRequireDefault(_global); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function postHeaderHeight() { var header = document.querySelector('.variate-header_full-height'); if (!header) { return false; } var style = getComputedStyle(header); var pos = header.getBoundingClientRect(); var scrollTop = _global2.default.scrollBox && _global2.default.scrollBox.scrollTop || window.pageYOffset || document.body.scrollTop || 0; var height = window.innerHeight - (scrollTop + parseInt(pos.top, 10)); header.style.minHeight = height - parseInt(style.paddingTop ? style.paddingTop.replace(/px|%/g, '') : '0', 10) + 'px'; } /***/ }) }]);