PageSourceSearch

https://absolwent.targi.pl/wp-content/themes/caards/assets/js/scripts.js?ver=1.0.0

js absolwent.targi.pl collected 2026-10-08 07:15:46 UTC 85,243 bytes, 2,575 lines download raw bytes

1/******/ (function(modules) { // webpackBootstrap
2/******/ 	// The module cache
3/******/ 	var installedModules = {};
4/******/
5/******/ 	// The require function
6/******/ 	function __webpack_require__(moduleId) {
7/******/
8/******/ 		// Check if module is in cache
9/******/ 		if(installedModules[moduleId]) {
10/******/ 			return installedModules[moduleId].exports;
11/******/ 		}
12/******/ 		// Create a new module (and put it into the cache)
13/******/ 		var module = installedModules[moduleId] = {
14/******/ 			i: moduleId,
15/******/ 			l: false,
16/******/ 			exports: {}
17/******/ 		};
18/******/
19/******/ 		// Execute the module function
20/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
21/******/
22/******/ 		// Flag the module as loaded
23/******/ 		module.l = true;
24/******/
25/******/ 		// Return the exports of the module
26/******/ 		return module.exports;
27/******/ 	}
28/******/
29/******/
30/******/ 	// expose the modules object (__webpack_modules__)
31/******/ 	__webpack_require__.m = modules;
32/******/
33/******/ 	// expose the module cache
34/******/ 	__webpack_require__.c = installedModules;
35/******/
36/******/ 	// define getter function for harmony exports
37/******/ 	__webpack_require__.d = function(exports, name, getter) {
38/******/ 		if(!__webpack_require__.o(exports, name)) {
39/******/ 			Object.defineProperty(exports, name, {
40/******/ 				configurable: false,
41/******/ 				enumerable: true,
42/******/ 				get: getter
43/******/ 			});
44/******/ 		}
45/******/ 	};
46/******/
47/******/ 	// getDefaultExport function for compatibility with non-harmony modules
48/******/ 	__webpack_require__.n = function(module) {
49/******/ 		var getter = module && module.__esModule ?
50/******/ 			function getDefault() { return module['default']; } :
51/******/ 			function getModuleExports() { return module; };
52/******/ 		__webpack_require__.d(getter, 'a', getter);
53/******/ 		return getter;
54/******/ 	};
55/******/
56/******/ 	// Object.prototype.hasOwnProperty.call
57/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
58/******/
59/******/ 	// __webpack_public_path__
60/******/ 	__webpack_require__.p = "";
61/******/
62/******/ 	// Load entry module and return exports
63/******/ 	return __webpack_require__(__webpack_require__.s = 1);
64/******/ })
65/************************************************************************/
66/******/ ([
67/* 0 */
68/***/ (function(module, exports, __webpack_require__) {
69
70"use strict";
71
72
73Object.defineProperty(exports, "__esModule", {
74  value: true
75});
76exports.$window = exports.$doc = exports.$body = exports.$ = void 0;
77exports.csGetCookie = csGetCookie;
78exports.csSetCookie = csSetCookie;
79exports.csThrottleScroll = csThrottleScroll;
80exports.wndW = exports.wndH = exports.docH = exports.csco = void 0;
81// Create csco object.
82var csco = {
83  addAction: function addAction(x, y, z) {
84    return;
85  }
86};
87exports.csco = csco;
88
89if ('undefined' !== typeof wp && 'undefined' !== typeof wp.hooks) {
90  csco.addAction = wp.hooks.addAction;
91}
92/**
93 * Window size
94 */
95
96
97var $ = jQuery;
98exports.$ = $;
99var $window = $(window);
100exports.$window = $window;
101var $doc = $(document);
102exports.$doc = $doc;
103var $body = $('body');
104exports.$body = $body;
105var wndW = 0;
106exports.wndW = wndW;
107var wndH = 0;
108exports.wndH = wndH;
109var docH = 0;
110exports.docH = docH;
111
112function csGetWndSize() {
113  exports.wndW = wndW = $window.width();
114  exports.wndH = wndH = $window.height();
115  exports.docH = docH = $doc.height();
116}
117
118$window.on('resize load orientationchange', csGetWndSize);
119csGetWndSize();
120/**
121 * Throttle scroll
122 * thanks: https://jsfiddle.net/mariusc23/s6mLJ/31/
123 */
124
125var csHideOnScrollList = [];
126var csDidScroll;
127var csLastST = 0;
128$window.on('scroll load resize orientationchange', function () {
129  if (csHideOnScrollList.length) {
130    csDidScroll = true;
131  }
132});
133
134function csHasScrolled() {
135  var ST = $window.scrollTop();
136  var type = null;
137
138  if (ST > csLastST) {
139    type = 'down';
140  } else if (ST < csLastST) {
141    type = 'up';
142  } else {
143    type = 'none';
144  }
145
146  if (ST === 0) {
147    type = 'start';
148  } else if (ST >= docH - wndH) {
149    type = 'end';
150  }
151
152  csHideOnScrollList.forEach(function (item) {
153    if (typeof item === 'function') {
154      item(type, ST, csLastST, $window);
155    }
156  });
157  csLastST = ST;
158}
159
160setInterval(function () {
161  if (csDidScroll) {
162    csDidScroll = false;
163    window.requestAnimationFrame(csHasScrolled);
164  }
165}, 250);
166
167function csThrottleScroll(callback) {
168  csHideOnScrollList.push(callback);
169}
170/**
171 * In Viewport checker
172 */
173
174
175$.fn.isInViewport = function () {
176  var elementTop = $(this).offset().top;
177  var elementBottom = elementTop + $(this).outerHeight();
178  var viewportTop = $(window).scrollTop();
179  var viewportBottom = viewportTop + $(window).height();
180  return elementBottom > viewportTop && elementTop < viewportBottom;
181};
182/**
183 * Cookies
184 */
185
186
187function csGetCookie(name) {
188  var matches = document.cookie.match(new RegExp("(?:^|; )" + name.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g, '\\$1') + "=([^;]*)"));
189  return matches ? decodeURIComponent(matches[1]) : undefined;
190}
191
192function csSetCookie(name, value) {
193  var props = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
194  props = {
195    path: '/'
196  };
197
198  if (props.expires instanceof Date) {
199    props.expires = props.expires.toUTCString();
200  }
201
202  var updatedCookie = encodeURIComponent(name) + "=" + encodeURIComponent(value);
203
204  for (var optionKey in props) {
205    updatedCookie += "; " + optionKey;
206    var optionValue = props[optionKey];
207
208    if (optionValue !== true) {
209      updatedCookie += "=" + optionValue;
210    }
211  }
212
213  document.cookie = updatedCookie;
214}
215
216/***/ }),
217/* 1 */
218/***/ (function(module, exports, __webpack_require__) {
219
220__webpack_require__(2);
221__webpack_require__(3);
222__webpack_require__(4);
223__webpack_require__(5);
224__webpack_require__(6);
225__webpack_require__(7);
226__webpack_require__(8);
227__webpack_require__(9);
228__webpack_require__(10);
229__webpack_require__(11);
230__webpack_require__(12);
231__webpack_require__(13);
232__webpack_require__(14);
233__webpack_require__(15);
234__webpack_require__(16);
235__webpack_require__(17);
236__webpack_require__(18);
237__webpack_require__(19);
238module.exports = __webpack_require__(20);
239
240
241/***/ }),
242/* 2 */
243/***/ (function(module, exports, __webpack_require__) {
244
245"use strict";
246
247
248var _utility = __webpack_require__(0);
249
250(function () {
251  function initCarousel() {
252    /**
253     * Wide Carousel Type 1
254     */
255    (0, _utility.$)('.cnvs-block-posts-layout-wide-type-1 ').each(function (indexBlock, objectBlock) {
256      (0, _utility.$)(objectBlock).imagesLoaded(function (instance) {
257        var rtl = _utility.$body.hasClass('rtl') ? true : false; // Loop.
258
259        (0, _utility.$)(instance.elements).each(function (index, el) {
260          var objectSlider = (0, _utility.$)(el).find('.cs-carousel__items');
261          var $current; // Point.
262
263          var point = function point() {
264            var points = [340, 370, 480, 576, 640, 768, 1020, 1200, 1280, 1434, 1584, 1780, 1920];
265            var current = 0;
266
267            for (var i in points) {
268              if (window.innerWidth >= points[i]) {
269                current = points[i];
270              }
271            }
272
273            return current;
274          }; // Get columns.
275
276
277          var carouselColumns = parseInt(window.getComputedStyle((0, _utility.$)(objectBlock)[0]).getPropertyValue('--cs-carousel-columns')); // Get data.
278
279          var autoPlay = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('autoplay'),
280              pageDots = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('pagedots'),
281              wrapAround = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('wraparound');
282          var settings = {
283            cellAlign: rtl ? 'right' : 'left',
284            autoPlay: autoPlay ? 5000 : false,
285            prevNextButtons: false,
286            rightToLeft: rtl,
287            wrapAround: wrapAround ? true : false,
288            pageDots: pageDots ? true : false,
289            resize: true
290          };
291          (0, _utility.$)(objectSlider).flickity(settings);
292          var flkty = (0, _utility.$)(objectSlider).data('flickity');
293          var $prev = (0, _utility.$)(objectBlock).find('.cs-carousel__arrow-previous');
294          var $next = (0, _utility.$)(objectBlock).find('.cs-carousel__arrow-next');
295          var elCount = (0, _utility.$)(objectSlider).find('.cs-carousel__cell').length;
296
297          if (elCount >= carouselColumns + 1) {
298            (0, _utility.$)(objectSlider).flickity(settings);
299          } else {
300            (0, _utility.$)(objectSlider).flickity('destroy');
301          }
301 // Set current point();
302
303
304          $current = point();
305
306          function updateCounter() {
307            var carouselCurrentWrapper = (0, _utility.$)(objectBlock).find('.cs-carousel__counters'),
308                carouselCurrentCounter = (0, _utility.$)(objectBlock).find('.cs-carousel__counters-current'),
309                carouselTotalCounter = (0, _utility.$)(objectBlock).find('.cs-carousel__counters-total');
310            var slideNumber = flkty.selectedIndex + 1,
311                totalNumber = flkty.slides.length;
312            carouselCurrentCounter.text(slideNumber);
313            carouselTotalCounter.text(totalNumber);
314            carouselCurrentWrapper.addClass('cs-carousel__counters-visible');
315          }
316
317          updateCounter();
318          (0, _utility.$)(objectSlider).on('change.flickity', updateCounter); // Resize.
319
320          (0, _utility.$)(window).resize(function () {
321            var carouselColumnsResize = parseInt(window.getComputedStyle((0, _utility.$)(objectBlock)[0]).getPropertyValue('--cs-carousel-columns'));
322
323            if ($current !== point() && elCount >= carouselColumnsResize + 1) {
324              (0, _utility.$)(objectSlider).flickity(settings);
325              $current = point();
326
327              if ((0, _utility.$)(objectSlider).flickity(settings)) {
328                (0, _utility.$)(objectSlider).flickity('destroy');
329                (0, _utility.$)(objectSlider).flickity(settings);
330              }
331            } else if ($current !== point() && elCount <= carouselColumnsResize && (0, _utility.$)(objectSlider).flickity(settings)) {
332              (0, _utility.$)(objectSlider).flickity('destroy');
333              $current = point();
334            }
335          }); // Select the previous slide.
336
337          $prev.on('click', function (event) {
338            event.preventDefault();
339            var type = rtl ? 'next' : 'previous';
340            (0, _utility.$)(objectSlider).flickity(type);
341          }); // Select the next slide.
342
343          $next.on('click', function (event) {
344            event.preventDefault();
345            var type = rtl ? 'previous' : 'next';
346            (0, _utility.$)(objectSlider).flickity(type);
347          });
348
349          if (!settings.wrapAround) {
350            (0, _utility.$)(objectSlider).on('select.flickity', function () {
351              // enable/disable previous/next buttons
352              if (!flkty.slides[flkty.selectedIndex - 1]) {
353                $prev.addClass('disabled');
354                $next.removeClass('disabled'); // <-- remove disabled from the next
355              } else if (!flkty.slides[flkty.selectedIndex + 1]) {
356                $next.addClass('disabled');
357                $prev.removeClass('disabled'); //<-- remove disabled from the prev
358              } else {
359                $prev.removeClass('disabled');
360                $next.removeClass('disabled');
361              }
362            });
363          }
364        });
365      });
366    });
367    /**
368     * Large Carousel Type 1
369     */
370
371    (0, _utility.$)('.cnvs-block-posts-layout-large-type-1').each(function (indexBlock, objectBlock) {
372      (0, _utility.$)(objectBlock).imagesLoaded(function (instance) {
373        var rtl = _utility.$body.hasClass('rtl') ? true : false; // Loop.
374
375        (0, _utility.$)(instance.elements).each(function (index, el) {
376          var objectSlider = (0, _utility.$)(el).find('.cs-carousel__items');
377          var $current; // Point.
378
379          var point = function point() {
380            var points = [340, 370, 480, 576, 640, 768, 1020, 1200, 1280, 1434, 1584, 1780, 1920];
381            var current = 0;
382
383            for (var i in points) {
384              if (window.innerWidth >= points[i]) {
385                current = points[i];
386              }
387            }
388
389            return current;
390          }; // Get columns.
391
392
393          var carouselColumns = parseInt(window.getComputedStyle((0, _utility.$)(objectBlock)[0]).getPropertyValue('--cs-carousel-columns')); // Get data.
394
395          var autoPlay = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('autoplay'),
396              pageDots = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('pagedots'),
397              wrapAround = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('wraparound'),
398              groupCells = (0, _utility.$)(objectBlock).find('.cs-flickity-init').data('groupcells');
399          var settings = {
400            wrapAround: wrapAround ? true : false,
401            groupCells: groupCells ? true : false,
402            autoPlay: autoPlay ? 5000 : false,
403            prevNextButtons: false,
404            pageDots: pageDots ? true : false,
405            rightToLeft: rtl,
406            resize: true,
407            selectedAttraction: 0.006,
408            friction: 0.14
409          };
410
411          if (settings.groupCells) {
412            settings.groupCells = carouselColumns;
413            (0, _utility.$)(objectSlider).addClass('cs-groupcells-active');
414          }
415
416          (0, _utility.$)(objectSlider).flickity(settings);
417          var flkty = (0, _utility.$)(objectSlider).data('flickity');
418          var $prev = (0, _utility.$)(objectBlock).find('.cs-carousel__arrow-previous');
419          var $next = (0, _utility.$)(objectBlock).find('.cs-carousel__arrow-next');
420          var elCount = (0, _utility.$)(objectSlider).find('.cs-carousel__cell').length;
421
422          if (elCount >= carouselColumns + 1) {
423            (0, _utility.$)(objectSlider).flickity(settings);
424          } else {
425            (0, _utility.$)(objectSlider).flickity('destroy');
426          } // Set current point();
427
428
429          $current = point();
430          var carouselCurrentWrapper = (0, _utility.$)('.cs-carousel__counters'),
431              carouselCurrentCounter = document.querySelector('.cs-carousel__counters-current'),
432              carouselTotalCounter = document.querySelector('.cs-carousel__counters-total');
433
434          function updateCounter() {
435            var slideNumber = flkty.selectedIndex + 1,
436                totalNumber = flkty.slides.length;
437            carouselCurrentCounter.textContent = slideNumber;
438            carouselTotalCounter.textContent = totalNumber;
439            carouselCurrentWrapper.addClass('cs-carousel__counters-visible');
440          }
441
442          updateCounter();
443          flkty.on('select', updateCounter); // Resize.
444
445          (0, _utility.$)(window).resize(function () {
446            var carouselColumnsResize = parseInt(window.getComputedStyle((0, _utility.$)(objectBlock)[0]).getPropertyValue('--cs-carousel-columns'));
447
448            if ($current !== point() && elCount >= carouselColumnsResize + 1) {
449              if (settings.groupCells) {
450                settings.groupCells = carouselColumnsResize;
451              }
452
453              (0, _utility.$)(objectSlider).flickity(settings);
454              $current = point();
455
456              if ((0, _utility.$)(objectSlider).flickity(settings)) {
457                (0, _utility.$)(objectSlider).flickity('destroy');
458
459                if (settings.groupCells) {
460                  settings.groupCells = carouselColumnsResize;
461                }
462
463                (0, _utility.$)(objectSlider).flickity(settings);
464              }
465            } else if ($current !== point() && elCount <= carouselColumnsResize && (0, _utility.$)(objectSlider).flickity(settings)) {
466              (0, _utility.$)(objectSlider).flickity('destroy');
467              $current = point();
468            }
469          }); // Select the previous slide.
470
471          $prev.on('click', function (event) {
472            event.preventDefault();
473            var type = rtl ? 'next' : 'previous';
474            (0, _utility.$)(objectSlider).flickity(type);
475          }); // Select the next slide.
476
477          $next.on('click', function (event) {
478            event.preventDefault();
479            var type = rtl ? 'previous' : 'next';
480            (0, _utility.$)(objectSlider).flickity(type);
481          });
482
483          if (!settings.wrapAround) {
484            (0, _utility.$)(objectSlider).on('select.flickity', function () {
485              // enable/disable previous/next buttons
486              if (!flkty.slides[flkty.selectedIndex - 1]) {
487                $prev.addClass('disabled');
488                $next.removeClass('disabled'); // <-- remove disabled from the next
489              } else if (!flkty.slides[flkty.selectedIndex + 1]) {
490                $next.addClass('disabled');
491                $prev.removeClass('disabled'); //<-- remove disabled from the prev
492              } else {
493                $prev.removeClass('disabled');
494                $next.removeClass('disabled');
495              }
496            });
497          }
498        });
499      });
500    });
501  }
502
503  function initTwitterWidgetCarousel() {
504    /*Twitter Carousel*/
505    (0, _utility.$)('.cs-twitter-carousel').each(function (indexBlock, objectBlock) {
506      (0, _utility.$)(objectBlock).imagesLoaded(function (instance) {
507        var rtl = _utility.$body.hasClass('rtl') ? true : false; // Loop.
508
509        (0, _utility.$)(instance.elements).each(function (index, el) {
510          var objectSlider = (0, _utility.$)(el).find('.cs-twitter-carousel__items'); // Get data.
511
512          var autoPlay = (0, _utility.$)(objectBlock).data('autoplay'),
513              wrapAround = (0, _utility.$)(objectBlock).data('wraparound');
514          var settings = {
515            cellAlign: rtl ? 'right' : 'left',
516            wrapAround: wrapAround ? true : false,
517            autoPlay: autoPlay ? 5000 : false,
518            prevNextButtons: false,
519            pageDots: true,
520            rightToLeft: rtl,
521            resize: true
522          };
523          (0, _utility.$)(objectSlider).flickity(settings);
524          var flkty = (0, _utility.$)(objectSlider).data('flickity');
525          var $prev = (0, _utility.$)(objectBlock).find('.carousel-previous');
526          var $next = (0, _utility.$)(objectBlock).find('.carousel-next');
527          var elCount = (0, _utility.$)(objectSlider).find('.cs-twitter-carousel__cell').length;
528
529          if (elCount >= 2) {
530            (0, _utility.$)(objectSlider).flickity(settings);
531          } else {
532            (0, _utility.$)(objectSlider).flickity('destroy');
533          } // Select the previous slide.
534
535
536          $prev.on('click', function (event) {
537            event.preventDefault();
538            var type = rtl ? 'next' : 'previous';
539            (0, _utility.$)(objectSlider).flickity(type);
540          }); // Select the next slide.
541
542          $next.on('click', function (event) {
543            event.preventDefault();
544            var type = rtl ? 'previous' : 'next';
545            (0, _utility.$)(objectSlider).flickity(type);
546          });
547
548          if (!settings.wrapAround) {
549            (0, _utility.$)(objectSlider).on('select.flickity', function () {
550              // enable/disable previous/next buttons
551              if (!flkty.slides[flkty.selectedIndex - 1]) {
552                $prev.addClass('disabled');
553                $next.removeClass('disabled'); // <-- remove disabled from the next
554              } else if (!flkty.slides[flkty.selectedIndex + 1]) {
555                $next.addClass('disabled');
556                $prev.removeClass('disabled'); //<-- remove disabled from the prev
557              } else {
558                $prev.removeClass('disabled');
559                $next.removeClass('disabled');
560              }
561            });
562          }
563        });
564      });
565    });
566  }
567
568  function initInstagramWidgetCarousel() {
569    /**
570     * Instagram Widget Slider
571     */
572    (0, _utility.$)('.pk-instagram-template-carousel .pk-instagram-items-carousel').imagesLoaded(function (instance) {
573      // Set unique id.
574      var requestId; // Set rtl status.
575
576      var rtl = (0, _utility.$)('body').hasClass('rtl') ? true : false;
577      (0, _utility.$)(instance.elements).each(function (index, el) {
578        var mainTicker = new Flickity(el, {
579          freeScroll: true,
580          accessibility: true,
581          resize: true,
582          wrapAround: true,
583          prevNextButtons: false,
584          pageDots: false,
585          percentPosition: true,
586          setGallerySize: true,
587          adaptiveHeight: true,
588          rightToLeft: rtl,
589          on: {
590            ready: function ready() {
591              (0, _utility.$)(el).addClass('is-animate');
592            }
593          }
594        });
595        mainTicker.initAnimation = false; // Set initial position to be 0
596
597        mainTicker.x = 0; // Main function that 'plays' the marquee.
598
599        function flickity_play() {
600          // Set the decrement of position x
601          mainTicker.x = mainTicker.x - 0.25; // Settle position into the slider
602
603          mainTicker.settle(mainTicker.x); // Set the requestId to the local letiable
604
605          requestId = window.requestAnimationFrame(flickity_play);
606        } // Main function to cancel the animation.
607
608
609        function flickity_pause() {
610          if (requestId) {
611            // Cancel the animation.
612            window.cancelAnimationFrame(requestId);
613            requestId = undefined;
614          }
615        } // Main function init
616
617
618        function flickity_init() {
619          // The monitor.
620          var isInView = (0, _utility.$)(el).isInViewport();
621
622          if (isInView) {
623            if (!mainTicker.initAnimation) {
624              flickity_play();
625              mainTicker.initAnimation = true;
626            }
627          } else {
628            flickity_pause();
629            mainTicker.initAnimation = false;
630          }
631        } // Document scroll.
632
633
634        (0, _utility.$)(window).on('load resize scroll', function () {
635          flickity_init();
636        }); // Document ready.
637
638        (0, _utility.$)(document).ready(function () {
639          flickity_init();
640        });
641      });
642    });
643  }
644
645  function initInstagramWidgetCarouselFull() {
646    /**
647     * Instagram Widget Slider
648     */
649    (0, _utility.$)('.pk-instagram-template-carousel-full .pk-instagram-items-carousel-full').imagesLoaded(function (instance) {
650      // Set unique id.
651      var requestId; // Set rtl status.
652
653      var rtl = (0, _utility.$)('body').hasClass('rtl') ? true : false;
654      (0, _utility.$)(instance.elements).each(function (index, el) {
655        var mainTicker = new Flickity(el, {
656          freeScroll: true,
657          accessibility: true,
658          resize: true,
659          wrapAround: true,
660          prevNextButtons: false,
661          pageDots: false,
662          percentPosition: true,
663          setGallerySize: true,
664          adaptiveHeight: true,
665          rightToLeft: rtl,
666          on: {
667            ready: function ready() {
668              (0, _utility.$)(el).addClass('is-animate');
669            }
670          }
671        });
672        mainTicker.initAnimation = false; // Set initial position to be 0
673
674        mainTicker.x = 0; // Main function that 'plays' the marquee.
675
676        function flickity_play() {
677          // Set the decrement of position x
678          mainTicker.x = mainTicker.x - 0.25; // Settle position into the slider
679
680          mainTicker.settle(mainTicker.x); // Set the requestId to the local letiable
681
682          requestId = window.requestAnimationFrame(flickity_play);
683        } // Main function to cancel the animation.
684
685
686        function flickity_pause() {
687          if (requestId) {
688            // Cancel the animation.
689            window.cancelAnimationFrame(requestId);
690            requestId = undefined;
691          }
692        } // Main function init
693
694
695        function flickity_init() {
696          // The monitor.
697          var isInView = (0, _utility.$)(el).isInViewport();
698
699          if (isInView) {
700            if (!mainTicker.initAnimation) {
701              flickity_play();
702              mainTicker.initAnimation = true;
703            }
704          } else {
705            flickity_pause();
706            mainTicker.initAnimation = false;
707          }
708        } // Document scroll.
709
710
711        (0, _utility.$)(window).on('load resize scroll', function () {
712          flickity_init();
713        }); // Document ready.
714
715        (0, _utility.$)(document).ready(function () {
716          flickity_init();
717        });
718      });
719    });
720  }
721
722  initCarousel();
723  initTwitterWidgetCarousel();
724  initInstagramWidgetCarousel();
725  initInstagramWidgetCarouselFull();
726  (0, _utility.$)(document).ready(function () {
727    (0, _utility.$)(document.body).on('post-load', function () {
728      initCarousel();
729      initTwitterWidgetCarousel();
730      initInstagramWidgetCarousel();
731      initInstagramWidgetCarouselFull();
732    });
733
734    _utility.csco.addAction('canvas.components.serverSideRender.onChange', 'init-carousel', function (props) {
735      if ('canvas/posts' === props.block) {
736        initCarousel();
737        initTwitterWidgetCarousel();
738        initInstagramWidgetCarousel();
739        initInstagramWidgetCarouselFull();
740      }
741    });
742  });
743})();
744
745/***/ }),
746/* 3 */
747/***/ (function(module, exports, __webpack_require__) {
748
749"use strict";
750
751
752var _utility = __webpack_require__(0);
753
754/** ----------------------------------------------------------------------------
755 * Comments Dropdown */
756(function () {
757  (0, _utility.$)(document).on('click', '.cs-entry__comments-show button', function (e) {
758    (0, _utility.$)('.cs-entry__comments-collapse').show();
759    (0, _utility.$)('.cs-entry__comments-show').remove();
760  });
761})();
762
763/***/ }),
764/* 4 */
765/***/ (function(module, exports, __webpack_require__) {
766
767"use strict";
768
769
770var _utility = __webpack_require__(0);
771
772/** ----------------------------------------------------------------------------
773 * Hover entry */
774(function () {
775  var buttonCopy = (0, _utility.$)('.cs-entry__after-share-buttons-copy');
776  var buttonCopyIcon = (0, _utility.$)('.cs-entry__after-share-buttons-copy .cs-icon');
777
778  function copyToClipboard() {
779    var inputCopy = (0, _utility.$)('.cs-entry__after-share-buttons-text');
780    inputCopy.select();
781    document.execCommand("copy");
782    buttonCopyIcon.removeClass('cs-icon-copy').addClass('cs-icon-check');
783    setTimeout(function () {
784      buttonCopyIcon.removeClass('cs-icon-check').addClass('cs-icon-copy');
785      inputCopy.blur();
786    }, 2000);
787  }
788
789  buttonCopy.on('click', function () {
790    copyToClipboard();
791  });
792})();
793
794/***/ }),
795/* 5 */
796/***/ (function(module, exports, __webpack_require__) {
797
798"use strict";
799
800
801var _utility = __webpack_require__(0);
802
803/** ----------------------------------------------------------------------------
804 * Detect Aligment */
805(function () {
806  var ticking = false;
807
808  var update = function update() {
809    // Sidebar.
810    // -----------------------------------.
811    (0, _utility.$)('.cs-site-primary').each(function () {
812      var content = (0, _utility.$)(this).find('.entry-content');
813      var sidebar = (0, _utility.$)(this).find('.cs-entry__metabar-inner'); // Vars offset.
814
815      var offsetTop = 20;
816      var offsetBottom = -20; // Search elements.
817
818      var elements = [];
819      elements.push('> .alignfull');
820      elements.push('> .alignwide');
821      var layouts = (0, _utility.$)(content).find(elements.join(','));
822
823      if (0 === sidebar.length) {
824        return;
825      }
826
827      if (0 === layouts.length) {
828        return;
829      }
830
831      var disabled = false; // Get sidebar values.
832
833      var sidebarTop = (0, _utility.$)(sidebar).offset().top;
834      var sidebarHeight = (0, _utility.$)(sidebar).outerHeight(true);
835
836      for (var i = 0; i < (0, _utility.$)(layouts).length; ++i) {
837        if ('none' === (0, _utility.$)(layouts[i]).css('transform')) {
838          continue;
839        } // Get layout values.
840
841
842        var layoutTop = (0, _utility.$)(layouts[i]).offset().top;
843        var layoutHeight = (0, _utility.$)(layouts[i]).outerHeight(true); // Calc points.
844
845        var pointTop = layoutTop - offsetTop;
846        var pointBottom = layoutTop + layoutHeight + offsetBottom; // Detect sidebar location.
847
848        if (sidebarTop + sidebarHeight >= pointTop && sidebarTop <= pointBottom) {
849          disabled = true;
850        }
851      }
852
853      if (disabled) {
854        (0, _utility.$)(sidebar).css('opacity', '0');
855      } else {
856        (0, _utility.$)(sidebar).css('opacity', '1');
857      }
858    }); // Ticking.
859
860    ticking = false;
861  };
862
863  var requestTick = function requestTick() {
864    if (!ticking) {
865      window.requestAnimationFrame(update);
866      ticking = true;
867    }
868  };
869
870  var onProcess = function onProcess() {
871    requestTick();
872  };
873
874  (0, _utility.$)(window).on('scroll', onProcess);
875  (0, _utility.$)(window).on('resize', onProcess);
876  (0, _utility.$)(window).on('image-load', onProcess);
877  (0, _utility.$)(window).on('post-load', onProcess);
878})();
879
880/***/ }),
881/* 6 */
882/***/ (function(module, exports, __webpack_require__) {
883
884"use strict";
885
886
887var _utility = __webpack_require__(0);
888
889/** ----------------------------------------------------------------------------
890 * Full Screen Menu */
891(function () {
892  var columns = (0, _utility.$)(".cs-fullscreen-menu__nav-col");
893  var menuLevel = 0;
894  var timeout = [];
895
896  _utility.$.fn.responsiveNav = function () {
897    this.removeClass('menu-item-expanded');
898
899    if (this.prev().hasClass('submenu-visible')) {
900      this.prev().removeClass('submenu-visible').slideUp(350);
901      this.parent().removeClass('menu-item-expanded');
902    } else {
903      this.parent().parent().find('.menu-item .sub-menu').removeClass('submenu-visible').slideUp(350);
904      this.parent().parent().find('.menu-item-expanded').removeClass('menu-item-expanded');
905      this.prev().toggleClass('submenu-visible').hide().slideToggle(350);
906      this.parent().toggleClass('menu-item-expanded');
907    }
908  };
909
910  (0, _utility.$)(document).ready(function (e) {
911    (0, _utility.$)('.cs-fullscreen-menu__nav-inner > .menu-item-has-children > .sub-menu > .menu-item-has-children > .sub-menu .menu-item-has-children').each(function (e) {
912      (0, _utility.$)(this).append('<span></span>');
913    });
914  });
915  (0, _utility.$)(document).on('click', '.cs-fullscreen-menu__nav-col-last > .sub-menu > .menu-item-has-children > span', function (e) {
916    e.preventDefault();
917    (0, _utility.$)(this).responsiveNav();
918  });
919  (0, _utility.$)(document).on('click', '.cs-fullscreen-menu__nav-col-last > .sub-menu > .menu-item-has-children > a', function (e) {
920    if ('#' === (0, _utility.$)(this).attr('href')) {
921      e.preventDefault();
922      (0, _utility.$)(this).next().next().responsiveNav();
923    }
924  });
925  (0, _utility.$)(document).on('mouseenter', '.cs-fullscreen-menu .menu-item', function (e) {
926    var submenu = (0, _utility.$)(this).children('.sub-menu').clone();
927
928    if ((0, _utility.$)(this).parents(".cs-fullscreen-menu__nav-inner").length > 0) {
929      menuLevel = 1;
930    } else if ((0, _utility.$)(this).parents(".cs-fullscreen-menu__nav-col-first").length > 0) {
931      menuLevel = 2;
932    } else if ((0, _utility.$)(this).parents(".cs-fullscreen-menu__nav-col-last").length > 0) {
933      menuLevel = 3;
934    }
935
936    if (submenu.length > 0) {
937      for (var i = 0; i < menuLevel; i++) {
938        clearTimeout(timeout[i]);
939      }
940    }
941
942    (0, _utility.$)(columns[menuLevel - 1]).html(submenu).addClass("visible");
943  });
944  (0, _utility.$)(document).on('mouseenter', '.cs-fullscreen-menu__nav-col, .cs-fullscreen-menu__nav-inner', function (e) {
945    if ((0, _utility.$)(this).hasClass("cs-fullscreen-menu__nav-inner")) {
946      menuLevel = 1;
947    } else if ((0, _utility.$)(this).hasClass("cs-fullscreen-menu__nav-col-first")) {
948      menuLevel = 2;
949    } else if ((0, _utility.$)(this).hasClass("cs-fullscreen-menu__nav-col-last")) {
950      menuLevel = 3;
951    }
952
953    for (var i = 0; i < menuLevel; i++) {
954      clearTimeout(timeout[i]);
955    }
956  });
957  (0, _utility.$)(document).on('mouseleave', '.cs-fullscreen-menu__nav-col, .cs-fullscreen-menu__nav-inner', function (e) {
958    timeout[0] = setTimeout(function () {
959      (0, _utility.$)(columns[0]).removeClass('visible');
960    }, 200);
961    timeout[1] = setTimeout(function () {
962      (0, _utility.$)(columns[1]).removeClass('visible');
963    }, 200);
964  });
965})();
966
967/***/ }),
968/* 7 */
969/***/ (function(module, exports, __webpack_require__) {
970
971"use strict";
972
973
974var _utility = __webpack_require__(0);
975
976/** ----------------------------------------------------------------------------
977 * Fullscreen */
978(function () {
979  (0, _utility.$)('.cs-header__fullscreen-menu-toggle').on('click', function (e) {
980    e.preventDefault();
981    (0, _utility.$)(this).toggleClass('active');
982
983    _utility.$body.toggleClass('cs-fullscreen-menu-active');
984
985    if ((0, _utility.$)('.cs-search').is(":visible")) {
986      (0, _utility.$)('.cs-search').slideUp();
987    }
988  });
989  (0, _utility.$)('.cs-fullscreen-menu__header-toggle').on('click', function (e) {
990    e.preventDefault();
991    (0, _utility.$)('.cs-header__fullscreen-menu-toggle').removeClass('active');
992
993    _utility.$body.toggleClass('cs-fullscreen-menu-active');
994  });
995})();
996
997/***/ }),
998/* 8 */
999/***/ (function(module, exports, __webpack_require__) {
1000
1001"use strict";
1002
1003
1004var _utility = __webpack_require__(0);
1005
1006/** ----------------------------------------------------------------------------
1007 * Hover entry */
1008(function () {
1009  var $entryType = (0, _utility.$)('.cs-block-posts-layout-tile-hover .cs-entry__outer'),
1010      isHovered = false;
1011
1012  function process(el) {
1013    var currentWidth = window.innerWidth,
1014        maxWidth = 1020,
1015        $el = null;
1016
1017    if (el) {
1018      $el = (0, _utility.$)(el);
1019    } else {
1020      $el = $entryType;
1021    }
1022
1023    if (currentWidth < maxWidth) {
1024      $entryType.attr('data-scheme', 'inverse');
1025    } else {
1026      $entryType.removeAttr('data-scheme');
1027
1028      if (isHovered) {
1029        $el.attr('data-scheme', 'inverse');
1030      } else {
1031        $entryType.removeAttr('data-scheme');
1032      }
1033    }
1034  }
1035
1036  $entryType.hover(function () {
1037    isHovered = true;
1038    process(this);
1039  }, function () {
1040    isHovered = false;
1041    process(this);
1042  });
1043
1044  _utility.$window.resize(function () {
1045    process();
1046  });
1047
1048  process();
1049})();
1050
1051/***/ }),
1052/* 9 */
1053/***/ (function(module, exports, __webpack_require__) {
1054
1055"use strict";
1056
1057
1058var _utility = __webpack_require__(0);
1059
1060function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
1061
1062if ('undefined' === typeof window.load_more_query) {
1063  window.load_more_query = [];
1064}
1065/**
1066 * Get next posts
1067 */
1068
1069
1070function csco_ajax_get_posts(object) {
1071  var container = (0, _utility.$)(object).closest('.cs-posts-area');
1072  var settings = (0, _utility.$)(object).data('settings');
1073  var page = (0, _utility.$)(object).data('page');
1074  (0, _utility.$)(object).data('loading', true); // Set button text to Load More.
1075
1076  (0, _utility.$)(object).addClass('loading');
1077  var data = {
1078    action: 'csco_ajax_load_more',
1079    page: page,
1080    posts_per_page: settings.posts_per_page,
1081    query_data: settings.query_data,
1082    attributes: settings.attributes,
1083    options: settings.options,
1084    _ajax_nonce: settings.nonce
1085  }; // Request Url.
1086
1087  var csco_pagination_url;
1088
1089  if ('ajax_restapi' === settings.type) {
1090    csco_pagination_url = settings.rest_url;
1091  } else {
1092    csco_pagination_url = settings.url;
1093  } // Send Request.
1094
1095
1096  _utility.$.post(csco_pagination_url, data, function (res) {
1097    if (res.success) {
1098      // Get the posts.
1099      var data = (0, _utility.$)(res.data.content); // Check if there're any posts.
1100
1101      if (data.length) {
1102        data.imagesLoaded(function () {
1103          // Append new posts to full, list, grid and masonry archives.
1104          if ((0, _utility.$)(container).find('.cs-posts-area__masonry').length > 0) {
1105            (0, _utility.$)(container).find('.cs-posts-area__masonry').colcade('append', data);
1106          } else if ((0, _utility.$)(container).find('.cs-block-posts-layout-masonry-type-1').length > 0) {
1107            (0, _utility.$)(container).find('.cs-block-posts-layout-masonry-type-1').colcade('append', data);
1108          } else {
1109            (0, _utility.$)(container).find('.cs-posts-area__main').append(data);
1110          } // WP Post Load trigger.
1111
1112
1113          (0, _utility.$)(document.body).trigger('post-load'); // Reinit Facebook widgets.
1114
1115          if ((0, _utility.$)('#fb-root').length && 'object' === (typeof FB === "undefined" ? "undefined" : _typeof(FB))) {
1116            FB.XFBML.parse();
1117          } // Set button text to Load More.
1118
1119
1120          (0, _utility.$)(object).removeClass('loading'); // Increment a page.
1121
1122          page = page + 1;
1123          (0, _utility.$)(object).data('page', page); // Set the loading state.
1124
1125          (0, _utility.$)(object).data('loading', false);
1126        });
1127      } // Remove Button on Posts End.
1128
1129
1130      if (res.data.posts_end || !data.length) {
1131        // Remove Load More button.
1132        (0, _utility.$)(object).remove();
1133      }
1134    } else {// console.log(res);
1135    }
1136  }).fail(function (xhr, textStatus, e) {// console.log(xhr.responseText);
1137  });
1138}
1139/**
1140 * Initialization Load More
1141 */
1142
1143
1144function csco_load_more_init(infinite) {
1145  (0, _utility.$)('.cs-posts-area').each(function () {
1146    if ((0, _utility.$)(this).data('init')) {
1147      return;
1148    }
1149
1150    var csco_ajax_settings;
1151
1152    if ((0, _utility.$)(this).hasClass('cs-posts-area-posts') && typeof csco_ajax_pagination !== 'undefined') {
1153      csco_ajax_settings = csco_ajax_pagination;
1154    }
1155
1156    var archive_data = (0, _utility.$)(this).data('posts-area');
1157
1158    if (archive_data) {
1159      csco_ajax_settings = JSON.parse(window.atob(archive_data));
1160    }
1161
1162    if (csco_ajax_settings) {
1163      if (!infinite && csco_ajax_settings.infinite_load) {
1164        return;
1165      } // Add load more button.
1166
1167
1168      (0, _utility.$)(this).append('<div class="cs-posts-area__pagination"><button class="cs-load-more"><span class="cs-button-label">' + csco_ajax_settings.translation.load_more + '</span><span class="cs-button-arrow"><span class="cs-loader-button"></span></button></div>'); // Set load more settings.
1169
1170      (0, _utility.$)(this).find('.cs-load-more').data('settings', csco_ajax_settings);
1171      (0, _utility.$)(this).find('.cs-load-more').data('page', 2);
1172      (0, _utility.$)(this).find('.cs-load-more').data('loading', false);
1173      (0, _utility.$)(this).find('.cs-load-more').data('scrollHandling', {
1174        allow: _utility.$.parseJSON(csco_ajax_settings.infinite_load),
1175        delay: 400
1176      });
1177    }
1178
1179    (0, _utility.$)(this).data('init', true);
1180  });
1181}
1182
1183csco_load_more_init(true);
1184
1185_utility.csco.addAction('canvas.components.serverSideRender.onChange', 'posts-init-loadmore', function (props) {
1186  if ('canvas/posts' === props.block) {
1187    csco_load_more_init(false);
1188  }
1189}); // On Scroll Event.
1190
1191
1192(0, _utility.$)(window).scroll(function () {
1193  (0, _utility.$)('.cs-posts-area .cs-load-more').each(function () {
1194    var loading = (0, _utility.$)(this).data('loading');
1195    var scrollHandling = (0, _utility.$)(this).data('scrollHandling');
1196
1197    if ('undefined' === typeof scrollHandling) {
1198      return;
1199    }
1200
1201    if ((0, _utility.$)(this).length && !loading && scrollHandling.allow) {
1202      scrollHandling.allow = false;
1203      (0, _utility.$)(this).data('scrollHandling', scrollHandling);
1204      var object = this;
1205      setTimeout(function () {
1206        var scrollHandling = (0, _utility.$)(object).data('scrollHandling');
1207
1208        if ('undefined' === typeof scrollHandling) {
1209          return;
1210        }
1211
1212        scrollHandling.allow = true;
1213        (0, _utility.$)(object).data('scrollHandling', scrollHandling);
1214      }, scrollHandling.delay);
1215      var offset = (0, _utility.$)(this).offset().top - (0, _utility.$)(window).scrollTop();
1216
1217      if (4000 > offset) {
1218        csco_ajax_get_posts(this);
1219      }
1220    }
1221  });
1222}); // On Click Event.
1223
1224(0, _utility.$)('body').on('click', '.cs-load-more', function () {
1225  var loading = (0, _utility.$)(this).data('loading');
1226
1227  if (!loading) {
1228    csco_ajax_get_posts(this);
1229  }
1230});
1231
1232/***/ }),
1233/* 10 */
1234/***/ (function(module, exports, __webpack_require__) {
1235
1236"use strict";
1237
1238
1239var _utility = __webpack_require__(0);
1240
1241function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
1242
1243/**
1244 * Check if Load Nextpost is defined by the wp_localize_script
1245 */
1246if (typeof csco_ajax_nextpost !== 'undefined') {
1247  var objNextparent = (0, _utility.$)('.cs-site-primary > .cs-site-content'),
1248      objNextsect = '.cs-nextpost-section',
1249      objNextpost = null,
1250      currentNTitle = document.title,
1251      currentNLink = window.location.href,
1252      loadingNextpost = false,
1253      scrollNextpost = {
1254    allow: true,
1255    reallow: function reallow() {
1256      scrollNextpost.allow = true;
1257    },
1258    delay: 400 //(milliseconds) adjust to the highest acceptable value
1259
1260  }; // Init.
1261
1262  if (csco_ajax_nextpost.next_post) {
1263    (0, _utility.$)(objNextparent).after('<div class="cs-nextpost-inner"></div>');
1264    objNextpost = (0, _utility.$)('.cs-nextpost-inner');
1265  }
1266}
1267/**
1268 * Get next post
1269 */
1270
1271
1272function csco_ajax_get_nextpost() {
1273  loadingNextpost = true; // Set class loading.
1274
1275  var data = {
1276    action: 'csco_ajax_load_nextpost',
1277    not_in: csco_ajax_nextpost.not_in,
1278    current_user: csco_ajax_nextpost.current_user,
1279    nonce: csco_ajax_nextpost.nonce,
1280    next_post: csco_ajax_nextpost.next_post
1281  }; // Request Url.
1282
1283  var csco_ajax_nextpost_url;
1284
1285  if ('ajax_restapi' === csco_ajax_nextpost.type) {
1286    csco_ajax_nextpost_url = csco_ajax_nextpost.rest_url;
1287  } else {
1288    csco_ajax_nextpost_url = csco_ajax_nextpost.url;
1289  } // Send Request.
1290
1291
1292  _utility.$.post(csco_ajax_nextpost_url, data, function (res) {
1293    csco_ajax_nextpost.next_post = false;
1294
1295    if (res.success) {
1296      // Get the posts.
1297      var data = (0, _utility.$)(res.data.content); // Check if there're any posts.
1298
1299      if (data.length) {
1300        // Set the loading state.
1301        loadingNextpost = false; // Set not_in.
1302
1303        csco_ajax_nextpost.not_in = res.data.not_in; // Set next data.
1304
1305        csco_ajax_nextpost.next_post = res.data.next_post; // Remove loader.
1306
1307        (0, _utility.$)(objNextpost).siblings('.cs-nextpost-loading').remove(); // Append new post.
1308
1309        (0, _utility.$)(objNextpost).append(data); // Reinit facebook.
1310
1311        if ((0, _utility.$)('#fb-root').length && 'object' === (typeof FB === "undefined" ? "undefined" : _typeof(FB))) {
1312          FB.XFBML.parse();
1313        }
1314
1315        (0, _utility.$)(document.body).trigger('post-load');
1316      }
1317    } else {// console.log(res);
1318    }
1319  }).fail(function (xhr, textStatus, e) {// console.log(xhr.responseText);
1320  });
1321}
1322/**
1323 * Check if Load Nextpost is defined by the wp_localize_script
1324 */
1325
1326
1327if (typeof csco_ajax_nextpost !== 'undefined') {
1328  // On Scroll Event.
1329  (0, _utility.$)(window).scroll(function () {
1330    var scrollTop = (0, _utility.$)(window).scrollTop(); // Init nextpost.
1331
1332    if (csco_ajax_nextpost.next_post) {
1333      if (objNextpost.length && !loadingNextpost && scrollNextpost.allow) {
1334        scrollNextpost.allow = false;
1335        setTimeout(scrollNextpost.reallow, scrollNextpost.delay); // Calc current offset.
1336
1337        var offset = objNextpost.offset().top + objNextpost.innerHe
1337ight() - scrollTop; // Load nextpost.
1338
1339        if (4000 > offset) {
1340          (0, _utility.$)(objNextpost).after('<div class="cs-nextpost-loading"></div>');
1341          csco_ajax_get_nextpost();
1342        }
1343      }
1344    } // Reset browser data link.
1345
1346
1347    var objFirst = (0, _utility.$)(objNextsect).first();
1348
1349    if (objFirst.length) {
1350      var firstTop = (0, _utility.$)(objFirst).offset().top; // If there has been a change.
1351
1352      if (scrollTop < firstTop && window.location.href !== currentNLink) {
1353        document.title = currentNTitle;
1354        window.history.pushState(null, currentNTitle, currentNLink);
1355      }
1356    } // Set browser data link.
1357
1358
1359    (0, _utility.$)(objNextsect).each(function (index, elem) {
1360      var elemTop = (0, _utility.$)(elem).offset().top;
1361      var elemHeight = (0, _utility.$)(elem).innerHeight();
1362
1363      if (scrollTop > elemTop && scrollTop < elemTop + elemHeight) {
1364        // If there has been a change.
1365        if (window.location.href !== (0, _utility.$)(elem).data('url')) {
1366          // New title.
1367          document.title = (0, _utility.$)(elem).data('title'); // New link.
1368
1369          window.history.pushState(null, (0, _utility.$)(elem).data('title'), (0, _utility.$)(elem).data('url')); // Google Analytics.
1370
1371          if (typeof gtag === 'function' && _typeof(window.gaData) === 'object') {
1372            var trackingId = Object.keys(window.gaData)[0];
1373
1374            if (trackingId) {
1375              gtag('config', trackingId, {
1376                'page_title': (0, _utility.$)(elem).data('title'),
1377                'page_location': (0, _utility.$)(elem).data('url')
1378              });
1379              gtag('event', 'page_view', {
1380                'send_to': trackingId
1381              });
1382            }
1383          }
1384        }
1385      }
1386    });
1387  });
1388}
1389
1390/***/ }),
1391/* 11 */
1392/***/ (function(module, exports, __webpack_require__) {
1393
1394"use strict";
1395
1396
1397var _utility = __webpack_require__(0);
1398
1399(function () {
1400  function initMasonry() {
1401    (0, _utility.$)('.cs-posts-area__masonry, .cs-block-posts-layout-masonry-type-1').each(function (index, block) {
1402      (0, _utility.$)(block).append("<div class=\"cs-posts-area__masonry-col cs-posts-area__masonry-col-1\"></div>\n\t\t\t\t<div class=\"cs-posts-area__masonry-col cs-posts-area__masonry-col-2\"></div>\n\t\t\t\t<div class=\"cs-posts-area__masonry-col cs-posts-area__masonry-col-3\"></div>\n\t\t\t\t<div class=\"cs-posts-area__masonry-col cs-posts-area__masonry-col-4\"></div>");
1403      (0, _utility.$)(block).colcade({
1404        columns: '.cs-posts-area__masonry-col',
1405        items: '.cs-posts-area-card'
1406      });
1407    });
1408  }
1409
1410  (0, _utility.$)(document).ready(function () {
1411    initMasonry();
1412
1413    _utility.csco.addAction('canvas.components.serverSideRender.onChange', 'init-carousel', function (props) {
1414      if ('canvas/posts' === props.block) {
1415        initMasonry();
1416      }
1417    });
1418  });
1419})();
1420
1421/***/ }),
1422/* 12 */
1423/***/ (function(module, exports, __webpack_require__) {
1424
1425"use strict";
1426
1427
1428var _utility = __webpack_require__(0);
1429
1430/** ----------------------------------------------------------------------------
1431 * Mega Menu */
1432(function () {
1433  /*
1434  * Load Mega Menu Posts
1435  */
1436  function cscoLoadMenuPosts(menuItem) {
1437    var dataTerm = menuItem.children('a').data('term'),
1438        dataPosts = menuItem.children('a').data('posts'),
1439        dataNumberposts = menuItem.children('a').data('numberposts'),
1440        menuContainer,
1441        postsContainer; // Containers.
1442
1443    if (menuItem.hasClass('cs-mega-menu-term')) {
1444      menuContainer = menuItem;
1445      postsContainer = menuContainer.find('.cs-mm__posts');
1446    }
1447
1448    if (menuItem.hasClass('cs-mega-menu-posts')) {
1449      menuContainer = menuItem;
1450      postsContainer = menuContainer.find('.cs-mm__posts');
1451    }
1452
1453    if (menuItem.hasClass('cs-mega-menu-child-term')) {
1454      menuContainer = menuItem.closest('.sub-menu');
1455      postsContainer = menuContainer.find('.cs-mm__posts[data-term="' + dataTerm + '"]');
1456    } // Check Menu Container.
1457
1458
1459    if (!menuContainer || typeof menuContainer === 'undefined') {
1460      return false;
1461    } // Check Container.
1462
1463
1464    if (!postsContainer || typeof postsContainer === 'undefined') {
1465      return false;
1466    } // Set Active.
1467
1468
1469    menuContainer.find('.menu-item, .cs-mm__posts').removeClass('cs-active-item');
1470    menuItem.addClass('cs-active-item');
1471
1472    if (postsContainer) {
1473      postsContainer.addClass('cs-active-item');
1474    } // Check Loading.
1475
1476
1477    if (menuItem.hasClass('cs-mm-loading') || menuItem.hasClass('loaded')) {
1478      return false;
1479    } // Create Data.
1480
1481
1482    var data = {
1483      'term': dataTerm,
1484      'posts': dataPosts,
1485      'per_page': dataNumberposts
1486    };
1487
1488    if ('undefined' === typeof csco_mega_menu) {
1489      return;
1490    } // Get Results.
1491
1492
1493    _utility.$.ajax({
1494      url: csco_mega_menu.rest_url,
1495      type: 'GET',
1496      data: data,
1497      global: false,
1498      async: true,
1499      beforeSend: function beforeSend() {
1500        menuItem.addClass('cs-mm-loading');
1501        postsContainer.addClass('cs-mm-loading');
1502      },
1503      success: function success(res) {
1504        if (res.status && 'success' === res.status) {
1505          // Set the loaded state.
1506          menuItem.addClass('loaded');
1507          postsContainer.addClass('loaded'); // Check if there're any posts.
1508
1509          if (res.content && res.content.length) {
1510            (0, _utility.$)(res.content).imagesLoaded(function () {
1511              // Append Data.
1512              postsContainer.html(res.content);
1513            });
1514          }
1515        }
1516      },
1517      complete: function complete() {
1518        // Set the loading state.
1519        menuItem.removeClass('cs-mm-loading');
1520        postsContainer.removeClass('cs-mm-loading');
1521      }
1522    });
1523  }
1524  /*
1525  * Get First Tab
1526  */
1527
1528
1529  function cscoGetFirstTab(container) {
1530    var firstTab = false;
1531    container.find('.cs-mega-menu-child').each(function (index, el) {
1532      if ((0, _utility.$)(el).hasClass('cs-mega-menu-child')) {
1533        firstTab = (0, _utility.$)(el);
1534        return false;
1535      }
1536    });
1537    return firstTab;
1538  }
1539  /*
1540  * Menu on document ready
1541  */
1542
1543
1544  (0, _utility.$)(document).ready(function () {
1545    /*
1546    * Get Menu Posts on Hover
1547    */
1548    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-posts').on('mouseenter', function () {
1549      cscoLoadMenuPosts((0, _utility.$)(this));
1550    });
1551    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-term').on('mouseenter', function () {
1552      cscoLoadMenuPosts((0, _utility.$)(this));
1553    });
1554    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-child').on('mouseenter', function () {
1555      cscoLoadMenuPosts((0, _utility.$)(this));
1556    });
1557    /*
1558    * Load First Tab on Mega Menu Hover
1559    */
1560
1561    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-terms').on('mouseenter', function () {
1562      var tab = cscoGetFirstTab((0, _utility.$)(this));
1563
1564      if (tab) {
1565        cscoLoadMenuPosts(tab);
1566      }
1567    });
1568  });
1569  /*
1570  * Load First Tab on Navbar Ready.
1571  */
1572
1573  (0, _utility.$)(document, '.cs-header__nav').ready(function () {
1574    var tab = false; // Autoload First Tab.
1575
1576    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-terms').each(function (index, el) {
1577      tab = cscoGetFirstTab((0, _utility.$)(this));
1578
1579      if (tab) {
1580        cscoLoadMenuPosts(tab);
1581      }
1582    }); // Autoload Posts.
1583
1584    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-posts').each(function (index, el) {
1585      cscoLoadMenuPosts((0, _utility.$)(this));
1586    }); // Autoload Term.
1587
1588    (0, _utility.$)('.cs-header__nav .menu-item.cs-mega-menu-term').each(function (index, el) {
1589      cscoLoadMenuPosts((0, _utility.$)(this));
1590    });
1591  });
1592})();
1593
1594/***/ }),
1595/* 13 */
1596/***/ (function(module, exports, __webpack_require__) {
1597
1598"use strict";
1599
1600
1601var _utility = __webpack_require__(0);
1602
1603/** ----------------------------------------------------------------------------
1604 * Navigation */
1605var cscoNavigation = {};
1606
1607(function () {
1608  var $this;
1609  cscoNavigation = {
1610    /** Initialize */
1611    init: function init(e) {
1612      if ((0, _utility.$)('body').hasClass('wp-admin')) {
1613        return;
1614      }
1615
1616      var headerStretch = (0, _utility.$)('.cs-navbar-smart-enabled .cs-header-stretch');
1617
1618      if (headerStretch.length > 0) {
1619        (0, _utility.$)('.cs-site-inner').prepend("<div class=\"cs-header-stretch-copy\"> ".concat(headerStretch.html(), " </div>"));
1620
1621        if (headerStretch.hasClass('cs-header-one')) {
1622          (0, _utility.$)('.cs-header-stretch-copy').addClass('cs-header-one');
1623        }
1624
1625        if (headerStretch.hasClass('cs-header-two')) {
1626          (0, _utility.$)('.cs-header-stretch-copy').addClass('cs-header-two');
1627        }
1628
1629        if (headerStretch.hasClass('cs-header-three')) {
1630          (0, _utility.$)('.cs-header-stretch-copy').addClass('cs-header-three');
1631        }
1632
1633        if (headerStretch.hasClass('cs-header-four')) {
1634          (0, _utility.$)('.cs-header-stretch-copy').addClass('cs-header-four');
1635        }
1636      }
1637
1638      $this = cscoNavigation; // Init events.
1639
1640      $this.events(e);
1641    },
1642
1643    /** Events */
1644    events: function events(e) {
1645      // DOM Load
1646      document.addEventListener('DOMContentLoaded', function (e) {
1647        $this.smartLevels(e);
1648        $this.adaptTablet(e);
1649        $this.stickyScroll(e);
1650      }); // Resize
1651
1652      window.addEventListener('resize', function (e) {
1653        $this.smartLevels(e);
1654        $this.adaptTablet(e);
1655        $this.stickyScroll(e);
1656      });
1657    },
1658
1659    /** Smart multi-Level menu */
1660    smartLevels: function smartLevels(e) {
1661      var windowWidth = _utility.$window.width(); // Reset Calc.
1662
1663
1664      (0, _utility.$)('.cs-header__nav-inner li').removeClass('cs-sm__level');
1665      (0, _utility.$)('.cs-header__nav-inner li').removeClass('cs-sm-position-left cs-sm-position-right');
1666      (0, _utility.$)('.cs-header__nav-inner li .sub-menu').removeClass('cs-mm__position-init'); // Set Settings.
1667
1668      (0, _utility.$)('.cs-header__nav-inner > li.menu-item').not('.cs-mm').each(function (index, parent) {
1669        var position = 'cs-sm-position-right'; //right
1670
1671        var objPrevWidth = 0;
1672        (0, _utility.$)(parent).find('.sub-menu').each(function (index, el) {
1673          // Reset child levels.
1674          (0, _utility.$)(el).parent().next('li').addClass('cs-sm__level');
1675
1676          if ((0, _utility.$)(el).parent().hasClass('cs-sm__level')) {
1677            (0, _utility.$)(el).parent().removeClass('cs-mm-level');
1678            position = 'cs-sm-position-right'; //right
1679
1680            objPrevWidth = 0;
1681          } // Find out position items.
1682
1683
1684          var offset = (0, _utility.$)(el).offset();
1685          var objOffset = offset.left;
1686
1687          if ('cs-sm-position-right' === position && (0, _utility.$)(el).outerWidth() + objOffset > windowWidth) {
1688            position = 'cs-sm-position-left';
1689          }
1690
1691          if ('cs-sm-position-left' === position && objOffset - ((0, _utility.$)(el).outerWidth() + objPrevWidth) < 0) {
1692            position = 'cs-sm-position-right'; //right
1693          }
1694
1695          objPrevWidth = (0, _utility.$)(el).outerWidth();
1696          (0, _utility.$)(el).addClass('cs-sm-position-init').parent().addClass(position);
1697        });
1698      });
1699    },
1700
1701    /** Adapting nav bar for tablet */
1702    adaptTablet: function adaptTablet(e) {
1703      // Click outside.
1704      (0, _utility.$)(document).on('touchstart', function (e) {
1705        if (!(0, _utility.$)(e.target).closest('.cs-header__nav-inner').length) {
1706          (0, _utility.$)('.cs-header__nav-inner .menu-item-has-children').removeClass('submenu-visible');
1707        } else {
1708          (0, _utility.$)(e.target).parents('.menu-item').siblings().find('.menu-item').removeClass('submenu-visible');
1709          (0, _utility.$)(e.target).parents('.menu-item').siblings().closest('.menu-item').removeClass('submenu-visible');
1710        }
1711      });
1712      (0, _utility.$)('.cs-header__nav-inner .menu-item-has-children').each(function (e) {
1713        // Reset class.
1714        (0, _utility.$)(this).removeClass('submenu-visible'); // Remove expanded.
1715
1716        (0, _utility.$)(this).find('> a > .expanded').remove(); // Add a caret.
1717
1718        if ('ontouchstart' in document.documentElement) {
1719          (0, _utility.$)(this).find('> a').append('<span class="expanded"></span>');
1720        } // Check touch device.
1721
1722
1723        (0, _utility.$)(this).addClass('ontouchstart' in document.documentElement ? 'touch-device' : '');
1724        (0, _utility.$)('> a .expanded', this).on('touchstart', function (e) {
1725          e.preventDefault();
1726          (0, _utility.$)(this).closest('.menu-item-has-children').toggleClass('submenu-visible');
1727        });
1728
1729        if ('#' === (0, _utility.$)('> a', this).attr('href')) {
1730          (0, _utility.$)('> a', this).on('touchstart', function (e) {
1731            e.preventDefault();
1732
1733            if (!(0, _utility.$)(e.target).hasClass('expanded')) {
1734              (0, _utility.$)(this).closest('.menu-item-has-children').toggleClass('submenu-visible');
1735            }
1736          });
1737        }
1738      });
1739    },
1740
1741    /** Make nav bar sticky */
1742    stickyScroll: function stickyScroll(e) {
1743      // Get css variables
1744      var headerLargeHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-initial-height')),
1745          headerCompactHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height')),
1746          headerPadding = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-padding')),
1747          headerTopbar = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-topbar-height')); //Get header elements
1748
1749      var headerSmart = (0, _utility.$)('.cs-navbar-smart-enabled .cs-header, .cs-navbar-sticky-enabled .cs-header'),
1750          headerBefore = (0, _utility.$)('.cs-header-before'),
1751          headerStretch = (0, _utility.$)('.cs-navbar-smart-enabled .cs-header-stretch'),
1752          headerCopy = (0, _utility.$)('.cs-header-stretch-copy'),
1753          wpAdminBar = (0, _utility.$)('#wpadminbar'),
1754          headerSearch = (0, _utility.$)('.cs-search'); // Difference beetween small and big sizes of stretch header
1755
1756      var headerDelta;
1757
1758      if (headerStretch.length > 0) {
1759        headerDelta = headerLargeHeight - headerCompactHeight;
1760      } else {
1761        headerDelta = 0;
1762      } // Adminbar sizes
1763
1764
1765      var wpAdminBarHeight;
1766
1767      if (wpAdminBar.length > 0) {
1768        wpAdminBarHeight = wpAdminBar.outerHeight();
1769      } else {
1770        wpAdminBarHeight = 0;
1771      } // Header smart start position.
1772
1773
1774      var smartStart;
1775
1776      if (headerBefore.length > 0) {
1777        smartStart = headerBefore.offset().top;
1778      } else {
1779        if (headerSmart.length > 0) {
1780          smartStart = headerSmart.offset().top + wpAdminBarHeight;
1781        } else {
1782          smartStart = wpAdminBarHeight;
1783        }
1784      } // Set values to hide.
1785
1786
1787      var scrollPoint = 200,
1788          scrollPrev = 200,
1789          scrollUpAmount = 0;
1790      (0, _utility.$)(window).scroll(function () {
1791        var scrolled = (0, _utility.$)(window).scrollTop(),
1792            headerSmartPosition = headerSmart.length > 0 ? headerSmart.offset().top : 0;
1793
1794        if (scrolled > smartStart + headerDelta + scrollPoint + 10 && scrolled > scrollPrev) {
1795          if (headerStretch.length === 0) {
1796            if (scrolled > smartStart + headerLargeHeight + 200 + (headerPadding || 0) + (headerTopbar || 0)) {
1797              headerSmart.removeClass('cs-header-smart-visible');
1798            }
1799          }
1800
1801          if (headerStretch.length > 0 && scrolled > smartStart + headerDelta + headerLargeHeight + (headerPadding || 0) + (headerTopbar || 0)) {
1802            headerCopy.removeClass('cs-header-smart-visible');
1803          }
1804
1805          headerSearch.slideUp();
1806          (0, _utility.$)(document).trigger('sticky-nav-hide');
1807        } else {
1808          if (scrollUpAmount >= scrollPoint || scrolled === 0) {
1809            if (headerStretch.length > 0) {
1810              if (scrolled > smartStart + headerDelta + headerLargeHeight + (headerPadding || 0) + (headerTopbar || 0)) {
1811                headerCopy.addClass('cs-header-smart-visible');
1812                (0, _utility.$)(document).trigger('sticky-nav-visible');
1813              } else if (scrolled < smartStart + headerDelta + headerLargeHeight + (headerPadding || 0) + (headerTopbar || 0)) {
1814                headerCopy.removeClass('cs-header-smart-visible');
1815                (0, _utility.$)(document).trigger('sticky-nav-hide');
1816              }
1817            } else {
1818              headerSmart.addClass('cs-header-smart-visible');
1819              (0, _utility.$)(document).trigger('sticky-nav-visible');
1820            }
1821          }
1822        }
1823
1824        if (headerSmart.length > 0) {
1825          if (headerStretch.length === 0) {
1826            if (scrolled > smartStart + headerLargeHeight + (headerPadding || 0) + (headerTopbar || 0)) {
1827              headerSmart.addClass('cs-scroll-sticky');
1828
1829              _utility.$body.addClass('cs-header-scroll-sticky');
1830            } else if (headerSmartPosition <= smartStart) {
1831              headerSmart.removeClass('cs-scroll-sticky').removeClass('cs-header-smart-visible');
1832
1833              _utility.$body.removeClass('cs-header-scroll-sticky');
1834
1835              (0, _utility.$)(document).trigger('sticky-nav-hide');
1836            }
1837          }
1838        }
1839
1840        if (scrolled < scrollPrev) {
1841          scrollUpAmount += scrollPrev - scrolled;
1842        } else {
1843          scrollUpAmount = 0;
1844        }
1845
1846        if (wpAdminBar.length > 0 && _utility.wndW <= 600 && scrolled >= wpAdminBarHeight) {
1847          (0, _utility.$)(document).trigger('adminbar-mobile-scrolled');
1848        } else {
1849          (0, _utility.$)(document).trigger('adminbar-mobile-no-scrolled');
1850        }
1851
1852        scrollPrev = scrolled;
1853      });
1854    }
1855  };
1856})(); // Initialize.
1857
1858
1859cscoNavigation.init();
1860
1861/***/ }),
1862/* 14 */
1863/***/ (function(module, exports, __webpack_require__) {
1864
1865"use strict";
1866
1867
1868var _utility = __webpack_require__(0);
1869
1870/** ----------------------------------------------------------------------------
1871 * Offcanvas */
1872(function () {
1873  (0, _utility.$)('.cs-header__offcanvas-toggle, .cs-site-overlay, .cs-offcanvas__toggle').on('click', function (e) {
1874    e.preventDefault(); // Transition.
1875
1876    if (!_utility.$body.hasClass('cs-offcanvas-active')) {
1877      _utility.$body.addClass('cs-offcanvas-transition');
1878    } else {
1879      setTimeout(function () {
1880        _utility.$body.removeClass('cs-offcanvas-transition');
1881      }, 400);
1882    } // Toogle offcanvas.
1883
1884
1885    _utility.$body.toggleClass('cs-offcanvas-active');
1886  });
1887})();
1888
1889/***/ }),
1890/* 15 */
1891/***/ (function(module, exports, __webpack_require__) {
1892
1893"use strict";
1894
1895
1896var _utility = __webpack_require__(0);
1897
1898/** ----------------------------------------------------------------------------
1899 * Hover player control */
1900(function () {
1901  (0, _utility.$)('.cs-player-control').hover(function () {
1902    (0, _utility.$)(this).siblings('.cs-player-control').css('opacity', '0.5');
1903  }, function () {
1904    (0, _utility.$)(this).siblings('.cs-player-control').css('opacity', '1');
1905  });
1906})();
1907
1908/***/ }),
1909/* 16 */
1910/***/ (function(module, exports, __webpack_require__) {
1911
1912"use strict";
1913
1914
1915var _utility = __webpack_require__(0);
1916
1917/** ----------------------------------------------------------------------------
1918 * Color Scheme Toogle */
1919var cscoDarkMode = {};
1920
1921(function () {
1922  var $this;
1923  cscoDarkMode = {
1924    /** Initialize */
1925    init: function init(e) {
1926      $this = cscoDarkMode; // Init events.
1927
1928      $this.events(e);
1929    },
1930
1931    /** Events */
1932    events: function events(e) {
1933      if ((0, _utility.$)('body').hasClass('wp-admin')) {
1934        return;
1935      } // DOM Load
1936
1937
1938      window.addEventListener('load', function (e) {
1939        $this.initMode(e);
1940      });
1941      window.matchMedia('(prefers-color-scheme: dark)').addListener(function (e) {
1942        $this.initMode(e);
1943      }); // Switch
1944
1945      (0, _utility.$)(document).on('click', '.cs-site-scheme-toggle', function (e) {
1946        $this.changeMode(e);
1947      });
1948    },
1949
1950    /** Detect Color Scheme */
1951    detectColorScheme: function detectColorScheme(color) {
1952      var level = 190; // Set alpha channel.
1953
1954      var alpha = 1;
1955      var rgba = [255, 255, 255];
1956      var color_rgba = false; // Trim color.
1957
1958      color = color.trim(); // If HEX format.
1959
1960      if ('#' === color[0]) {
1961        // Remove '#' from start.
1962        color = color.replace('#', '').trim();
1963
1964        if (3 === color.length) {
1965          color = color[0] + color[0] + color[1] + color[1] + color[2] + color[2];
1966        }
1967
1968        rgba[0] = parseInt(color.substr(0, 2), 16);
1969        rgba[1] = parseInt(color.substr(2, 2), 16);
1970        rgba[2] = parseInt(color.substr(4, 2), 16);
1971      } else if (color_rgba = color.replace(/\s/g, '').match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i)) {
1972        // Convert RGB or RGBA.
1973        rgba[0] = parseInt(color_rgba[1]);
1974        rgba[1] = parseInt(color_rgba[2]);
1975        rgba[2] = parseInt(color_rgba[3]);
1976
1977        if (color_rgba[4] !== undefined) {
1978          alpha = parseFloat(color_rgba[4]);
1979        }
1980      } // Apply alpha channel.
1981
1982
1983      rgba.forEach(function myFunction(channel, key, stack) {
1984        stack[key] = String(channel + Math.ceil((255 - channel) * (1 - alpha))).padStart(2, '0');
1985      }); // Set default scheme.
1986
1987      var scheme = 'default'; // Get brightness.
1988
1989      var brightness = (rgba[0] * 299 + rgba[1] * 587 + rgba[2] * 114) / 1000; // If color gray.
1990
1991      if (rgba[0] === rgba[1] && rgba[1] === rgba[2]) {
1992        if (brightness < level) {
1993          scheme = 'dark';
1994        }
1995      } else {
1996        if (brightness < level) {
1997          scheme = 'inverse';
1998        }
1999      }
2000
2001      return scheme;
2002    },
2003
2004    /** Set Individual Scheme */
2005    setIndividualScheme: function setIndividualScheme() {
2006      var list = {
2007        'body': '--cs-color-site-background',
2008        '.cs-topbar': '--cs-color-topbar-background',
2009        '.cs-header': '--cs-color-header-background',
2010        '.cs-header__nav-inner .sub-menu': '--cs-color-submenu-background',
2011        '.cs-header__multi-column-container': '--cs-color-submenu-background',
2012        '.cs-header__widgets': '--cs-color-submenu-background',
2013        '.cs-offcanvas__header': '--cs-color-header-background',
2014        '.cs-search': '--cs-color-search-background',
2015        '.cs-footer': '--cs-color-footer-background',
2016        '.cs-fullscreen-menu': '--cs-color-fullscreen-menu-background',
2017        '.cs-header__featured-column-container': '--cs-color-featured-column-background'
2018      };
2019
2020      for (var key in list) {
2021        if ((0, _utility.$)(key).length <= 0) {
2022          continue;
2023        }
2024        /* jshint ignore:start */
2025
2026
2027        (0, _utility.$)(key).each(function (index, element) {
2028          var color = window.getComputedStyle((0, _utility.$)(element)[0]).getPropertyValue(list[key]);
2029          var scheme = $this.detectColorScheme(color);
2030          (0, _utility.$)(element).attr('data-scheme', scheme);
2031        });
2032        /* jshint ignore:end */
2033      }
2034    },
2035
2036    /** Init Mode */
2037    initMode: function initMode(e) {
2038      // Get system scheme.
2039      var systemSchema = 'default';
2040
2041      if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
2042        systemSchema = 'dark';
2043      }
2044
2045      (0, _utility.csSetCookie)('_color_system_schema', systemSchema, {
2046        expires: 2592000
2047      }); // Set site scheme.
2048
2049      var siteScheme = 'default';
2050
2051      switch (csLocalize.siteSchemeMode) {
2052        case 'dark':
2053          siteScheme = 'dark';
2054          break;
2055
2056        case 'light':
2057          siteScheme = 'default';
2058          break;
2059
2060        case 'system':
2061          siteScheme = systemSchema;
2062          break;
2063      }
2064
2065      if (csLocalize.siteSchemeToogle) {
2066        if ('default' === (0, _utility.csGetCookie)('_color_schema')) {
2067          siteScheme = 'default';
2068        }
2069
2070        if ('dark' === (0, _utility.csGetCookie)('_color_schema')) {
2071          siteScheme = 'dark';
2072        }
2073      } // Change site scheme
2074
2075
2076      if (siteScheme !== _utility.$body.attr('data-site-scheme')) {
2077        $this.changeScheme(siteScheme, false);
2078      }
2079    },
2080
2081    /** Change Mode */
2082    changeMode: function changeMode(e) {
2083      if ('dark' === _utility.$body.attr('data-site-scheme')) {
2084        $this.changeScheme('default', true);
2085      } else {
2086        $this.changeScheme('dark', true);
2087      }
2088    },
2089
2090    /** Change Scheme */
2091    changeScheme: function changeScheme(scheme, cookie) {
2092      _utility.$body.addClass('cs-scheme-toggled');
2093
2094      _utility.$body.attr('data-site-scheme', scheme);
2095
2096      $this.setIndividualScheme();
2097
2098      if (cookie) {
2099        (0, _utility.csSetCookie)('_color_schema', scheme, {
2100          expires: 2592000
2101        });
2102        (0, _utility.csSetCookie)('_color_system_schema', null, {
2103          expires: 2592000
2104        });
2105      }
2106
2107      setTimeout(function () {
2108        _utility.$body.removeClass('cs-scheme-toggled');
2109      }, 100);
2110    }
2111  };
2112})(); // Initialize.
2113
2114
2115cscoDarkMode.init();
2116
2117/***/ }),
2118/* 17 */
2119/***/ (function(module, exports, __webpack_require__) {
2120
2121"use strict";
2122
2123
2124var _utility = __webpack_require__(0);
2125
2126/** ----------------------------------------------------------------------------
2127 * Search Dropdown */
2128(function () {
2129  var focusSearchTimeout;
2130  (0, _utility.$)('.cs-header__search-toggle').click(function (e) {
2131    if (!(0, _utility.$)('.cs-search').is(":visible")) {
2132      focusSearchTimeout = setTimeout(function () {
2133        (0, _utility.$)('.cs-search .cs-search__input').focus();
2134      }, 300);
2135    } else {
2136      clearTimeout(focusSearchTimeout);
2137    }
2138
2139    if (_utility.$body.hasClass('cs-search-type-two')) {
2140      (0, _utility.$)('.cs-search').stop().fadeIn();
2141
2142      _utility.$body.addClass('cs-search-type-two-visible');
2143    } else {
2144      (0, _utility.$)('.cs-search').stop().fadeToggle();
2145    }
2146
2147    e.preventDefault();
2148  });
2149  (0, _utility.$)('.cs-search__input').keypress(function (e) {
2150    if (13 === e.which) {
2151      (0, _utility.$)(this).closest('form').submit();
2152      return false;
2153    }
2154  });
2155  (0, _utility.$)('.cs-search__close').click(function (e) {
2156    (0, _utility.$)('.cs-search').fadeOut();
2157
2158    _utility.$body.removeClass('cs-search-type-two-visible');
2159
2160    e.preventDefault();
2161    clearTimeout(focusSearchTimeout);
2162  });
2163})();
2164
2165/***/ }),
2166/* 18 */
2167/***/ (function(module, exports, __webpack_require__) {
2168
2169"use strict";
2170
2171
2172var _utility = __webpack_require__(0);
2173
2174/** ----------------------------------------------------------------------------
2175 * Sticky Sidebar */
2176(function () {
2177  var stickyElementsSmart = [],
2178      stickyElements = [];
2179  stickyElementsSmart.push('.cs-navbar-smart-enabled .cs-entry__metabar-inner');
2180  stickyElementsSmart.push('.cs-sticky-sidebar-enabled.cs-navbar-smart-enabled.cs-stick-to-top .cs-sidebar__inner');
2181  stickyElementsSmart.push('.cs-sticky-sidebar-enabled.cs-navbar-smart-enabled.cs-stick-last .cs-sidebar__inner .widget:last-child');
2182  stickyElementsSmart.push('.cs-sticky-sidebar-enabled.cs-navbar-smart-enabled .cnvs-block-section-sidebar-sticky-top .cnvs-block-section-sidebar-inner');
2183  stickyElementsSmart.push('.cs-sticky-sidebar-enabled.cs-navbar-smart-enabled .cnvs-block-section-sidebar-sticky-top-last-block .cnvs-block-section-sidebar-inner > :last-child');
2184  stickyElements.push('.cs-navbar-sticky-enabled .cs-entry__metabar-inner');
2185  stickyElements.push('.cs-sticky-sidebar-enabled.cs-navbar-sticky-enabled.cs-stick-to-top .cs-sidebar__inner');
2186  stickyElements.push('.cs-sticky-sidebar-enabled.cs-navbar-sticky-enabled.cs-stick-last .cs-sidebar__inner .widget:last-child');
2187  stickyElements.push('.cs-sticky-sidebar-enabled.cs-navbar-sticky-enabled .cnvs-block-section-sidebar-sticky-top .cnvs-block-section-sidebar-inner');
2188  stickyElements.push('.cs-sticky-sidebar-enabled.cs-navbar-sticky-enabled .cnvs-block-section-sidebar-sticky-top-last-block .cnvs-block-section-sidebar-inner > :last-child');
2189
2190  _utility.$doc.ready(function () {
2191    var headerStick = (0, _utility.$)('.cs-header'),
2192        wpAdminBar = (0, _utility.$)('#wpadminbar'),
2193        wpAdminBarHeight = wpAdminBar.outerHeight(),
2194        headerStretch = (0, _utility.$)('.cs-header-stretch'),
2195        headerSmart = (0, _utility.$)('.cs-navbar-smart-enabled .cs-header'),
2196        headerStretchHeight = headerSmart.length > 0 ? parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height')) : headerStick.outerHeight(),
2197        headerStickHeight = headerSmart.length > 0 ? parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height')) : headerStick.outerHeight(),
2198        headerScrollHeight = 0,
2199        allHeight = (headerStickHeight || 0) + (wpAdminBarHeight || 0) + 20,
2200        windowWidth = (0, _utility.$)(window).width(); // Sticky sidebar for mozilla.
2201
2202    if (navigator.userAgent.toLowerCase().indexOf('firefox') > -1) {
2203      stickyElementsSmart.push('.cs-sticky-sidebar-enabled.cs-stick-to-bottom .cs-sidebar__inner');
2204      stickyElements.push('.cs-sticky-sidebar-enabled.cs-stick-to-bottom .cs-sidebar__inner');
2205    } // Join elements.
2206
2207
2208    stickyElementsSmart = stickyElementsSmart.join(',');
2209    stickyElements = stickyElements.join(','); // header scroll show
2210
2211    _utility.$doc.on('entry-header-scrolled', function () {
2212      headerScrollHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height'));
2213    }); // header scroll hide
2214
2215
2216    _utility.$doc.on('entry-header-no-scrolled', function () {
2217      headerScrollHeight = 0;
2218    }); // Sticky nav visible.
2219
2220
2221    _utility.$doc.on('sticky-nav-visible', function () {
2222      headerStickHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height'));
2223
2224      if (headerStretchHeight) {
2225        allHeight = (headerStretchHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2226      } else {
2227        allHeight = (headerStickHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2228      }
2229
2230      (0, _utility.$)(stickyElementsSmart).css('top', allHeight + 'px'); // alert(allHeight);
2231    }); // Sticky nav hide.
2232
2233
2234    _utility.$doc.on('sticky-nav-hide', function () {
2235      headerStickHeight = 0;
2236      allHeight = (headerStickHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2237      (0, _utility.$)(stickyElementsSmart).css('top', allHeight + 'px');
2238    });
2239
2240    _utility.$doc.on('stretch-nav-to-small', function () {
2241      headerStretchHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-height'));
2242
2243      if (headerStretchHeight) {
2244        allHeight = (headerStretchHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2245      } else {
2246        allHeight = (headerStickHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2247      }
2248
2249      if (headerStretch.hasClass("cs-scroll-sticky") && !headerStretch.hasClass("cs-scroll-active")) {
2250        (0, _utility.$)(stickyElementsSmart).css('top', allHeight + 'px');
2251      }
2252    });
2253
2254    _utility.$doc.on('stretch-nav-to-big', function () {
2255      headerStretchHeight = parseInt(getComputedStyle(document.documentElement).getPropertyValue('--cs-header-initial-height'));
2256    }); // Add top style
2257
2258
2259    if (_utility.$body.hasClass('cs-navbar-smart-enabled') && windowWidth >= 1020) {
2260      if (headerStretchHeight) {
2261        allHeight = (headerStretchHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2262      } else {
2263        allHeight = (headerStickHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2264      }
2265
2266      (0, _utility.$)(stickyElementsSmart).css('top', allHeight + 'px');
2267    } else if (_utility.$body.hasClass('cs-navbar-sticky-enabled') && windowWidth >= 1020) {
2268      if (headerStretchHeight) {
2269        allHeight = (headerStretchHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2270      } else {
2271        allHeight = (headerStickHeight || 0) + (headerScrollHeight || 0) + (wpAdminBarHeight || 0) + 20;
2272      }
2273
2274      (0, _utility.$)(stickyElements).css('top', allHeight + 'px');
2275    } // Remove top style rafter resize
2276
2277
2278    _utility.$window.resize(function () {
2279      var windowWidthResize = _utility.$window.width();
2280
2281      if (windowWidthResize < 1020) {
2282        (0, _utility.$)(stickyElements).removeAttr('style');
2283        (0, _utility.$)(stickyElementsSmart).removeAttr('style');
2284      }
2285    });
2286  });
2287})();
2288/*cs-navbar-sticky-enabled cs-navbar-smart-enabled*/
2289
2290/***/ }),
2291/* 19 */
2292/***/ (function(module, exports, __webpack_require__) {
2293
2294"use strict";
2295
2296
2297var _utility = __webpack_require__(0);
2298
2299/** ----------------------------------------------------------------------------
2300 * Video Background */
2301(function () {
2302  var initAPI = false;
2303  var process = false;
2304  var contex = [];
2305  var players = [];
2306  var attrs = []; // Create deferred object
2307
2308  var YTdeferred = _utility.$.Deferred();
2309
2310  window.onYouTubePlayerAPIReady = function () {
2311    // Resolve when youtube callback is called
2312    // passing YT as a parameter.
2313    YTdeferred.resolve(window.YT);
2314  }; // Embedding youtube iframe api.
2315
2316
2317  function embedYoutubeAPI() {
2318    var tag = document.createElement('script');
2319    tag.src = 'https://www.youtube.com/iframe_api';
2320    var firstScriptTag = document.getElementsByTagName('script')[0];
2321    firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
2322  } // Video rescale.
2323
2324
2325  function rescaleVideoBackground() {
2326    (0, _utility.$)('.cs-video-init').each(function () {
2327      var w = (0, _utility.$)(this).parent().width();
2328      var h = (0, _utility.$)(this).parent().height();
2329      var hideControl = 400;
2330      var id = (0, _utility.$)(this).attr('data-uid');
2331
2332      if (w / h > 16 / 9) {
2333        players[id].setSize(w, w / 16 * 9 + hideControl);
2334      } else {
2335        players[id].setSize(h / 9 * 16, h + hideControl);
2336      }
2337    });
2338  } // Init video background.
2339
2340
2341  function initVideoBackground() {
2342    if ((0, _utility.$)('body').hasClass('wp-admin')) {
2343      return;
2344    }
2345
2346    if (process) {
2347      return;
2348    }
2349
2350    process = true; // Smart init API.
2351
2352    if (!initAPI) {
2353      var elements = (0, _utility.$)('.cs-video-wrapper[data-video-id]');
2354
2355      if (elements.length) {
2356        embedYoutubeAPI();
2357        initAPI = true;
2358      }
2359    }
2360
2361    if (!initAPI) {
2362      process = false;
2363      return;
2364    } // Whenever youtube callback was called = deferred resolved
2365    // your custom function will be executed with YT as an argument.
2366
2367
2368    YTdeferred.done(function (YT) {
2369      (0, _utility.$)('.cs-video-inner').each(function () {
2370        // The state.
2371        var isInit = (0, _utility.$)(this).hasClass('cs-video-init');
2372        var id = null; // Generate unique ID.
2373
2374        if (!isInit) {
2375          id = Math.random().toString(36).substr(2, 9);
2376        } else {
2377          id = (0, _utility.$)(this).attr('data-uid');
2378        } // Create contex.
2379
2380
2381        contex[id] = this; // The actived.
2382
2383        var isActive = (0, _utility.$)(contex[id]).hasClass('active'); // The monitor.
2384
2385        var isInView = (0, _utility.$)(contex[id]).isInViewport(); // Initialization.
2386
2387        if (isInView && !isInit) {
2388          // Add init class.
2389          (0, _utility.$)(contex[id]).addClass('cs-video-init'); // Add unique ID.
2390
2391          (0, _utility.$)(contex[id]).attr('data-uid', id); // Get video attrs.
2392
2393          var videoID = (0, _utility.$)(contex[id]).parent().data('video-id');
2394          var videoStart = (0, _utility.$)(contex[id]).parent().data('video-start');
2395          var videoEnd = (0, _utility.$)(contex[id]).parent().data('video-end'); // Check video id.
2396
2397          if (typeof videoID === 'undefined' || !videoID) {
2398            return;
2399          } // Video attrs.
2400
2401
2402          attrs[id] = {
2403            'videoId': videoID,
2404            'startSeconds': videoStart,
2405            'endSeconds': videoEnd,
2406            'suggestedQuality': 'hd720'
2407          }; // Creating a player.
2408
2409          players[id] = new YT.Player(contex[id], {
2410            playerVars: {
2411              autoplay: 0,
2412              autohide: 1,
2413              modestbranding: 1,
2414              rel: 0,
2415              showinfo: 0,
2416              controls: 0,
2417              disablekb: 1,
2418              enablejsapi: 0,
2419              iv_load_policy: 3,
2420              playsinline: 1,
2421              loop: 1
2422            },
2423            events: {
2424              'onReady': function onReady() {
2425                players[id].loadVideoById(attrs[id]);
2426                players[id].mute();
2427              },
2428              'onStateChange': function onStateChange(e) {
2429                if (e.data === 1) {
2430                  (0, _utility.$)(contex[id]).parents('.cs-overlay, .cs-video-wrap').addClass('cs-video-bg-init');
2431                  (0, _utility.$)(contex[id]).addClass('active');
2432                } else if (e.data === 0) {
2433                  players[id].seekTo(attrs[id].startSeconds);
2434                }
2435              }
2436            }
2437          });
2438          rescaleVideoBackground();
2439        } // Pause and play.
2440
2441
2442        var control = (0, _utility.$)(contex[id]).parents('.cs-overlay, .cs-video-wrap').find('.cs-player-state');
2443
2444        if (isActive && isInit && !(0, _utility.$)(control).hasClass('cs-player-upause')) {
2445          if (isInView && (0, _utility.$)(control).hasClass('cs-player-play')) {
2446            // Change icon.
2447            (0, _utility.$)(control).removeClass('cs-player-play').addClass('cs-player-pause'); // Pause video.
2448
2449            players[id].playVideo();
2450          }
2451
2452          if (!isInView && (0, _utility.$)(control).hasClass('cs-player-pause')) {
2453            // Change icon.
2454            (0, _utility.$)(control).removeClass('cs-player-pause').addClass('cs-player-play'); // Pause video.
2455
2456            players[id].pauseVideo();
2457          }
2458        }
2459      });
2460    });
2461    process = false;
2462  } // State Control.
2463
2464
2465  _utility.$doc.on('click', '.cs-player-state', function () {
2466    var container = (0, _utility.$)(this).parents('.cs-overlay, .cs-video-wrap').find('.cs-video-inner');
2467    var id = (0, _utility.$)(container).attr('data-uid');
2468    (0, _utility.$)(this).toggleClass('cs-player-pause cs-player-play');
2469
2470    if ((0, _utility.$)(this).hasClass('cs-player-pause')) {
2471      (0, _utility.$)(this).removeClass('cs-player-upause');
2472      players[id].playVideo();
2473    } else {
2474      (0, _utility.$)(this).addClass('cs-player-upause');
2475      players[id].pauseVideo();
2476    }
2477  }); // Stop Control.
2478
2479
2480  _utility.$doc.on('click', '.cs-player-stop', function () {
2481    var container = (0, _utility.$)(this).parents('.cs-overlay, .cs-video-wrap').find('.cs-video-inner');
2482    var id = (0, _utility.$)(container).attr('data-uid');
2483    (0, _utility.$)(this).siblings('.cs-player-state').removeClass('cs-player-pause').addClass('cs-player-play');
2484    (0, _utility.$)(this).siblings('.cs-player-state').addClass('cs-player-upause');
2485    players[id].pauseVideo();
2486  }); // Volume Control.
2487
2488
2489  _utility.$doc.on('click', '.cs-player-volume', function () {
2490    var container = (0, _utility.$)(this).parents('.cs-overlay, .cs-video-wrap').find('.cs-video-inner');
2491    var id = (0, _utility.$)(container).attr('data-uid');
2492    (0, _utility.$)(this).toggleClass('cs-player-mute cs-player-unmute');
2493
2494    if ((0, _utility.$)(this).hasClass('cs-player-unmute')) {
2495      players[id].unMute();
2496    } else {
2497      players[id].mute();
2498    }
2499  }); // Document scroll.
2500
2501
2502  _utility.$window.on('load scroll resize scrollstop', function () {
2503    initVideoBackground();
2504  }); // Document ready.
2505
2506
2507  _utility.$doc.ready(function () {
2508    initVideoBackground();
2509  }); // Post load.
2510
2511
2512  _utility.$body.on('post-load', function () {
2513    initVideoBackground();
2514  }); // Document resize.
2515
2516
2517  _utility.$window.on('resize', function () {
2518    rescaleVideoBackground();
2519  }); // Init.
2520
2521
2522  initVideoBackground();
2523})();
2524
2525/***/ }),
2526/* 20 */
2527/***/ (function(module, exports, __webpack_require__) {
2528
2529"use strict";
2530
2531
2532var _utility = __webpack_require__(0);
2533
2534/** ----------------------------------------------------------------------------
2535 * Widget Nav Menu */
2536(function () {
2537  _utility.$.fn.responsiveNav = function () {
2538    this.removeClass('menu-item-expanded');
2539
2540    if (this.prev().hasClass('submenu-visible')) {
2541      this.prev().removeClass('submenu-visible').slideUp(350);
2542      this.parent().removeClass('menu-item-expanded');
2543    } else {
2544      this.parent().parent().find('.menu-item .sub-menu').removeClass('submenu-visible').slideUp(350);
2545      this.parent().parent().find('.menu-item-expanded').removeClass('menu-item-expanded');
2546      this.prev().toggleClass('submenu-visible').hide().slideToggle(350);
2547      this.parent().toggleClass('menu-item-expanded');
2548    }
2549  }; //
2550  // Navigation Menu Widget
2551  //
2552
2553
2554  (0, _utility.$)(document).ready(function (e) {
2555    (0, _utility.$)('.widget_nav_menu .menu-item-has-children').each(function (e) {
2556      // Add a caret.
2557      (0, _utility.$)(this).append('<span></span>'); // Fire responsiveNav() when clicking a caret.
2558
2559      (0, _utility.$)('> span', this).on('click', function (e) {
2560        e.preventDefault();
2561        (0, _utility.$)(this).responsiveNav();
2562      }); // Fire responsiveNav() when clicking a parent item with # href attribute.
2563
2564      if ('#' === (0, _utility.$)('> a', this).attr('href')) {
2565        (0, _utility.$)('> a', this).on('click', function (e) {
2566          e.preventDefault();
2567          (0, _utility.$)(this).next().next().responsiveNav();
2568        });
2569      }
2570    });
2571  });
2572})();
2573
2574/***/ })
2575/******/ ]);

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.