PageSourceSearch

https://patientsolutionsllc.com/wp-content/themes/patsolutions/assets/js/modules.js?ver=7.1.2

js patientsolutionsllc.com collected 2026-10-04 08:00:51 UTC 68,322 bytes, 2,159 lines download raw bytes

1(function($) {
2	"use strict";
3
4	window.digiwake = {};
5	digiwake.modules = {};
6
7	digiwake.scroll = 0;
8	digiwake.window = $(window);
9	digiwake.document = $(document);
10	digiwake.windowWidth = $(window).width();
11	digiwake.windowHeight = $(window).height();
12	digiwake.body = $('body');
13	digiwake.html = $('html, body');
14	digiwake.htmlEl = $('html');
15	digiwake.menuDropdownHeightSet = false;
16	digiwake.defaultHeaderStyle = '';
17	digiwake.minVideoWidth = 1500;
18	digiwake.videoWidthOriginal = 1280;
19	digiwake.videoHeightOriginal = 720;
20	digiwake.videoRatio = 1280 / 720;
21
22	digiwake.digiwakeOnDocumentReady = digiwakeOnDocumentReady;
23	digiwake.digiwakeOnWindowLoad = digiwakeOnWindowLoad;
24	digiwake.digiwakeOnWindowResize = digiwakeOnWindowResize;
25	digiwake.digiwakeOnWindowScroll = digiwakeOnWindowScroll;
26
27	$(document).ready(digiwakeOnDocumentReady);
28	$(window).load(digiwakeOnWindowLoad);
29	$(window).resize(digiwakeOnWindowResize);
30	$(window).scroll(digiwakeOnWindowScroll);
31
32	/* 
33	All functions to be called on $(document).ready() should be in this function
34	*/
35	function digiwakeOnDocumentReady() {
36		digiwake.scroll = $(window).scrollTop();
37	}
38
39	/* 
40	All functions to be called on $(window).load() should be in this function
41	*/
42	function digiwakeOnWindowLoad() {
43	}
44
45	/* 
46	All functions to be called on $(window).resize() should be in this function
47	*/
48	function digiwakeOnWindowResize() {
49		digiwake.windowWidth = $(window).width();
50		digiwake.windowHeight = $(window).height();
51	}
52
53	/* 
54	All functions to be called on $(window).scroll() should be in this function
55	*/
56	function digiwakeOnWindowScroll() {
57		digiwake.scroll = $(window).scrollTop();
58	}
59
60	//set boxed layout width variable for various calculations
61
62	switch (true) {
63	case digiwake.body.hasClass('digiwake-grid-1300'):
64		digiwake.boxedLayoutWidth = 1350;
65		break;
66	case digiwake.body.hasClass('digiwake-grid-1200'):
67		digiwake.boxedLayoutWidth = 1250;
68		break;
69	case digiwake.body.hasClass('digiwake-grid-1000'):
70		digiwake.boxedLayoutWidth = 1050;
71		break;
72	case digiwake.body.hasClass('digiwake-grid-800'):
73		digiwake.boxedLayoutWidth = 850;
74		break;
75	default:
76		digiwake.boxedLayoutWidth = 1150;
77		break;
78	}
79}
80)(jQuery);
81
82(function($) {
83	"use strict";
84
85	var header = {};
86	digiwake.modules.header = header;
87
88	header.isStickyVisible = false;
89	header.stickyAppearAmount = 0;
90	header.stickyMobileAppearAmount = 0;
91	header.behaviour;
92	header.digiwakeInitMobileNavigation = digiwakeInitMobileNavigation;
93	header.digiwakeMobileHeaderBehavior = digiwakeMobileHeaderBehavior;
94	header.digiwakeSetDropDownMenuPosition = digiwakeSetDropDownMenuPosition;
95	header.digiwakeDropDownMenu = digiwakeDropDownMenu;
96	header.digiwakeSearch = digiwakeSearch;
97
98	header.digiwakeOnDocumentReady = digiwakeOnDocumentReady;
99	header.digiwakeOnWindowLoad = digiwakeOnWindowLoad;
100	header.digiwakeOnWindowResize = digiwakeOnWindowResize;
101	header.digiwakeOnWindowScroll = digiwakeOnWindowScroll;
102
103	$(document).ready(digiwakeOnDocumentReady);
104	$(window).load(digiwakeOnWindowLoad);
105	$(window).resize(digiwakeOnWindowResize);
106	$(window).scroll(digiwakeOnWindowScroll);
107
108	/* 
109	All functions to be called on $(document).ready() should be in this function
110	*/
111	function digiwakeOnDocumentReady() {
112		digiwakeHeaderBehaviour();
113		digiwakeInitMobileNavigation();
114		digiwakeMobileHeaderBehavior();
115		digiwakeSetDropDownMenuPosition();
116		digiwakeDropDownMenu();
117		digiwakeSearch();
118	}
119
120	/* 
121	All functions to be called on $(window).load() should be in this function
122	*/
123	function digiwakeOnWindowLoad() {
124		digiwakeSetDropDownMenuPosition();
125	}
126
127	/* 
128	All functions to be called on $(window).resize() should be in this function
129	*/
130	function digiwakeOnWindowResize() {
131		digiwakeDropDownMenu();
132	}
133
134	/* 
135	All functions to be called on $(window).scroll() should be in this function
136	*/
137	function digiwakeOnWindowScroll() {
138	}
139
140	/*
141	 ** Show/Hide sticky header on window scroll
142	 */
143	function digiwakeHeaderBehaviour() {
144
145		var header = $('.digiwake-page-header');
146		var stickyHeader = $('.digiwake-sticky-header');
147		var fixedHeaderWrapper = $('.digiwake-fixed-wrapper');
148
149		var headerMenuAreaOffset = $('.digiwake-page-header').find('.digiwake-fixed-wrapper').length ? $('.digiwake-page-header').find('.digiwake-fixed-wrapper').offset().top : null;
150
151		var stickyAppearAmount;
152
153		switch (true) {
154			// sticky header that will be shown when user scrolls up
155		case digiwake.body.hasClass('digiwake-sticky-header-on-scroll-up'):
156			digiwake.modules.header.behaviour = 'digiwake-sticky-header-on-scroll-up';
157			var docYScroll1 = $(document).scrollTop();
158			stickyAppearAmount = digiwakeGlobalVars.vars.digiwakeTopBarHeight + digiwakeGlobalVars.vars.digiwakeLogoAreaHeight + digiwakeGlobalVars.vars.digiwakeMenuAreaHeight + digiwakeGlobalVars.vars.digiwakeStickyHeaderHeight;
159
160			var headerAppear = function() {
161				var docYScroll2 = $(document).scrollTop();
162
163				if ((docYScroll2 > docYScroll1 && docYScroll2 > stickyAppearAmount) || (docYScroll2 < stickyAppearAmount)) {
164					digiwake.modules.header.isStickyVisible = false;
165					stickyHeader.removeClass('header-appear').find('.digiwake-main-menu .digiwake-menu-second').removeClass('digiwake-drop-down-start');
166				} else {
167					digiwake.modules.header.isStickyVisible = true;
168					stickyHeader.addClass('header-appear');
169				}
170
171				docYScroll1 = $(document).scrollTop();
172			};
173			headerAppear();
174
175			$(window).scroll(function() {
176				headerAppear();
177			});
178
179			break;
180
181			// sticky header that will be shown when user scrolls both up and down
182		case digiwake.body.hasClass('digiwake-sticky-header-on-scroll-down-up'):
183			digiwake.modules.header.behaviour = 'digiwake-sticky-header-on-scroll-down-up';
184
185			if (digiwakePerPageVars.vars.digiwakeStickyScrollAmount !== 0) {
186				digiwake.modules.header.stickyAppearAmount = digiwakePerPageVars.vars.digiwakeStickyScrollAmount;
187			} else {
188				digiwake.modules.header.stickyAppearAmount = digiwakeGlobalVars.vars.digiwakeStickyScrollAmount !== 0 ? digiwakeGlobalVars.vars.digiwakeStickyScrollAmount : digiwakeGlobalVars.vars.digiwakeTopBarHeight + digiwakeGlobalVars.vars.digiwakeLogoAreaHeight + digiwakeGlobalVars.vars.digiwakeMenuAreaHeight;
189			}
190
191			var headerAppear = function() {
192				if (digiwake.scroll < digiwake.modules.header.stickyAppearAmount) {
193					digiwake.modules.header.isStickyVisible = false;
194					stickyHeader.removeClass('header-appear').find('.digiwake-main-menu .digiwake-menu-second').removeClass('digiwake-drop-down-start');
195				} else {
196					digiwake.modules.header.isStickyVisible = true;
197					stickyHeader.addClass('header-appear');
198				}
199			};
200
201			headerAppear();
202
203			$(window).scroll(function() {
204				headerAppear();
205			});
206
207			break;
208
209			// on scroll down, part of header will be sticky
210		case digiwake.body.hasClass('digiwake-fixed-on-scroll'):
211			digiwake.modules.header.behaviour = 'digiwake-fixed-on-scroll';
212			var headerFixed = function() {
213				if (digiwake.scroll < headerMenuAreaOffset) {
214					fixedHeaderWrapper.removeClass('fixed');
215					header.css('margin-bottom', 0);
216				} else {
217					fixedHeaderWrapper.addClass('fixed');
218					header.css('margin-bottom', fixedHeaderWrapper.height());
219				}
220			};
221
222			headerFixed();
223
224			$(window).scroll(function() {
225				headerFixed();
226			});
227
228			break;
229		}
230	}
231
232	function digiwakeInitMobileNavigation() {
233		var navigationOpener = $('.digiwake-mobile-header .digiwake-mobile-menu-opener');
234		var navigationHolder = $('.digiwake-mobile-header .digiwake-mobile-nav');
235		var dropdownOpener = $('.digiwake-mobile-nav .mobile_arrow, .digiwake-mobile-nav h4, .digiwake-mobile-nav a[href*="#"]');
236		var animationSpeed = 200;
237
238		//whole mobile menu opening / closing
239		if (navigationOpener.length && navigationHolder.length) {
240			navigationOpener.on('tap click', function(e) {
241				e.stopPropagation();
242				e.preventDefault();
243
244				if (navigationHolder.is(':visible')) {
245					navigationHolder.slideUp(animationSpeed);
246				} else {
247					navigationHolder.slideDown(animationSpeed);
248				}
249			});
250		}
251
252		//dropdown opening / closing
253		if (dropdownOpener.length) {
254			dropdownOpener.each(function() {
255				$(this).on('tap click', function(e) {
256					var dropdownToOpen = $(this).nextAll('ul').first();
257
258					if (dropdownToOpen.length) {
259						e.preventDefault();
260						e.stopPropagation();
261
262						var openerParent = $(this).parent('li');
263						if (dropdownToOpen.is(':visible')) {
264							dropdownToOpen.slideUp(animationSpeed);
265							openerParent.removeClass('digiwake-opened');
266						} else {
267							dropdownToOpen.slideDown(animationSpeed);
268							openerParent.addClass('digiwake-opened');
269						}
270					}
271
272				});
273			});
274		}
275
276		$('.digiwake-mobile-nav a, .digiwake-mobile-logo-wrapper a').on('click tap', function(e) {
277			if ($(this).attr('href') !== 'http://#' && $(this).attr('href') !== '#') {
278				navigationHolder.slideUp(animationSpeed);
279			}
280		});
281	}
282
283	function digiwakeMobileHeaderBehavior() {
284		if (digiwake.body.hasClass('digiwake-sticky-up-mobile-header')) {
285			var stickyAppearAmount;
286			var topBar = $('.digiwake-top-bar');
287			var mobileHeader = $('.digiwake-mobile-header');
288			var adminBar = $('#wpadminbar');
289			var mobileHeaderHeight = mobileHeader.length ? mobileHeader.height() : 0;
290			var topBarHeight = topBar.is(':visible') ? topBar.height() : 0;
291			var adminBarHeight = adminBar.length ? adminBar.height() : 0;
292
293			var docYScroll1 = $(document).scrollTop();
294			digiwake.modules.header.stickyMobileAppearAmount = topBarHeight + mobileHeaderHeight + adminBarHeight;
295			stickyAppearAmount = digiwake.modules.header.stickyMobileAppearAmount;
296
297			$(window).scroll(function() {
298				var docYScroll2 = $(document).scrollTop();
299
300				if (docYScroll2 > stickyAppearAmount) {
301					mobileHeader.addClass('digiwake-animate-mobile-header');
302					mobileHeader.css('margin-bottom', mobileHeaderHeight);
303				} else {
304					mobileHeader.removeClass('digiwake-animate-mobile-header');
305					mobileHeader.css('margin-bottom', 0);
306				}
307
308				if ((docYScroll2 > docYScroll1 && docYScroll2 > stickyAppearAmount) || (docYScroll2 < stickyAppearAmount)) {
309					mobileHeader.removeClass('mobile-header-appear');
310					if (adminBar.length) {
311						mobileHeader.find('.digiwake-mobile-header-inner').css('top', 0);
312					}
313				} else {
314					mobileHeader.addClass('mobile-header-appear');
315
316				}
317
318				docYScroll1 = $(document).scrollTop();
319			});
320		}
321	}
322
323	/**
324	 * Set dropdown position
325	 */
326	function digiwakeSetDropDownMenuPosition() {
327
328		var menuItems = $(".digiwake-drop-down > ul > li.digiwake-menu-narrow");
329		menuItems.each(function(i) {
330
331			var browserWidth = digiwake.windowWidth - 16;
332			// 16 is width of scroll bar
333			var menuItemPosition = $(this).offset().left;
334			var dropdownMenuWidth = $(this).find('.digiwake-menu-second .digiwake-menu-inner ul').width();
335
336			var menuItemFromLeft = 0;
337			if (digiwake.body.hasClass('boxed')) {
338				menuItemFromLeft = digiwake.boxedLayoutWidth - (menuItemPosition - (browserWidth - digiwake.boxedLayoutWidth) / 2);
339			} else {
340				menuItemFromLeft = browserWidth - menuItemPosition;
341			}
342
343			var dropDownMenuFromLeft;
344			//has to stay undefined beacuse 'dropDownMenuFromLeft < dropdownMenuWidth' condition will be true
345
346			if ($(this).find('li.sub').length > 0) {
347				dropDownMenuFromLeft = menuItemFromLeft - dropdownMenuWidth;
348			}
349
350			if (menuItemFromLeft < dropdownMenuWidth || dropDownMenuFromLeft < dropdownMenuWidth) {
351				$(this).find('.digiwake-menu-second').addClass('right');
352				$(this).find('.digiwake-menu-second .digiwake-menu-inner ul').addClass('right');
353			}
354		});
355
356	}
357
358	function digiwakeDropDownMenu() {
359
360		var menu_items = $('.digiwake-drop-down > ul > li');
361
362		menu_items.each(function(i) {
363			if ($(menu_items[i]).find('.digiwake-menu-second').length > 0) {
364
365				var dropDownSecondDiv = $(menu_items[i]).find('.digiwake-menu-second');
366
367				if ($(menu_items[i]).hasClass('digiwake-menu-wide')) {
368
369					var dropdown = $(this).find('.digiwake-menu-inner > ul');
370					var dropdownPadding = parseInt(dropdown.css('padding-left').slice(0, -2)) + parseInt(dropdown.css('padding-right').slice(0, -2));
371					var dropdownWidth = dropdown.outerWidth();
372
373					if (!$(this).hasClass('digiwake-menu-left-position') && !$(this).hasClass('digiwake-menu-right-position')) {
374						dropDownSecondDiv.css('left', 0);
375					}
376
377					//set columns to be same height - start
378					var tallest = 0;
379					$(this).find('.digiwake-menu-second > .digiwake-menu-inner > ul > li').each(function() {
380						var thisHeight = $(this).height();
381						if (thisHeight > tallest) {
382							tallest = thisHeight;
383						}
384					});
385					$(this).find('.digiwake-menu-second > .digiwake-menu-inner > ul > li').css("height", "");
386					// delete old inline css - via resize
387					$(this).find('.digiwake-menu-second > .digiwake-menu-inner > ul > li').height(tallest);
388					//set columns to be same height - end
389
390					if (!$(this).hasClass('wide-background')) {
391						if (!$(this).hasClass('digiwake-menu-left-position') && !$(this).hasClass('digiwake-menu-right-position')) {
392							var left_position = (digiwake.windowWidth - 2 * (digiwake.windowWidth - dropdown.offset().left)) / 2 + (dropdownWidth + dropdownPadding) / 2;
393							dropDownSecondDiv.css('left', -left_position);
394						}
395					} else {
396						if (!$(this).hasClass('digiwake-menu-left-position') && !$(this).hasClass('digiwake-menu-right-position')) {
397							var left_position = dropdown.offset().left;
398
399							dropDownSecondDiv.css('left', -left_position);
400							dropDownSecondDiv.css('width', digiwake.windowWidth);
401
402						}
403					}
404				}
405
406				if (!digiwake.menuDropdownHeightSet) {
407					$(menu_items[i]).data('original_height', dropDownSecondDiv.height() + 'px');
408					dropDownSecondDiv.height(0);
409				}
410
411				if (navigator.userAgent.match(/(iPod|iPhone|iPad)/)) {
412					$(menu_items[i]).on("touchstart mouseenter", function() {
413						dropDownSecondDiv.css({
414							'height': $(menu_items[i]).data('original_height'),
415							'overflow': 'visible',
416							'visibility': 'visible',
417							'opacity': '1'
418						});
419					}).on("mouseleave", function() {
420						dropDownSecondDiv.css({
421							'height': '0px',
422							'overflow': 'hidden',
423							'visibility': 'hidden',
424							'opacity': '0'
425						});
426					});
427
428				} else {
429					if (digiwake.body.hasClass('digiwake-dropdown-animate-height')) {
430						$(menu_items[i]).mouseenter(function() {
431							dropDownSecondDiv.css({
432								'visibility': 'visible',
433								'height': '0px',
434								'opacity': '0'
435							});
436							dropDownSecondDiv.stop().animate({
437								'height': $(menu_items[i]).data('original_height'),
438								opacity: 1
439							}, 200, function() {
440								dropDownSecondDiv.css('overflow', 'visible');
441							});
442						}).mouseleave(function() {
443							dropDownSecondDiv.stop().animate({
444								'height': '0px'
445							}, 0, function() {
446								dropDownSecondDiv.css({
447									'overflow': 'hidden',
448									'visibility': 'hidden'
449								});
450							});
451						});
452					} else {
453						var config = {
454							interval: 0,
455							over: function() {
456								setTimeout(function() {
457									dropDownSecondDiv.addClass('digiwake-drop-down-start');
458									dropDownSecondDiv.stop().css({
459										'height': $(menu_items[i]).data('original_height')
460									});
461								}, 150);
462							},
463							timeout: 150,
464							out: function() {
465								dropDownSecondDiv.stop().css({
466									'height': '0px'
467								});
468								dropDownSecondDiv.removeClass('digiwake-drop-down-start');
469							}
470						};
471						$(menu_items[i]).hoverIntent(config);
472					}
473				}
474			}
475		});
476		$('.digiwake-drop-down ul li.digiwake-menu-wide ul li a').on('click', function(e) {
477			if (e.which == 1) {
478				var $this = $(this);
479				setTimeout(function() {
480					$this.mouseleave();
481				}, 500);
482			}
483		});
484
485		digiwake.menuDropdownHeightSet = true;
486	}
487
488	/**
489	 * Init Search Types
490	 */
491	function digiwakeSearch() {
492
493		var searchOpener = $('a.digiwake-search-opener'), searchClose, touch = false;
494
495		if ($('html').hasClass('touch')) {
496			touch = true;
497		}
498
499		if (searchOpener.length > 0) {
500
501			searchOpener.each(function() {
502				var thisSearchOpener = $(this);
503
504				//Check for type of search
505				if (digiwake.body.hasClass('digiwake-fullscreen-search')) {
506
507					var fullscreenSearchFade = false
508						, fullscreenSearchFromCircle = false;
509
510					searchClose = $('.digiwake-fullscreen-search-close');
511
512					if (digiwake.body.hasClass('digiwake-search-fade')) {
513						fullscreenSearchFade = true;
514					} else if (digiwake.body.hasClass('digiwake-search-from-circle')) {
515						fullscreenSearchFromCircle = true;
516					}
517					digiwakeFullscreenSearch(fullscreenSearchFade, fullscreenSearchFromCircle);
518
519				} else if (digiwake.body.hasClass('digiwake-search-covers-header')) {
520
521					digiwakeSearchCoversHeader();
522
523				}
524
525				//Check for hover color of search
526				if (typeof thisSearchOpener.data('hover-color') !== 'undefined') {
527					var changeSearchColor = function(event) {
528						event.data.searchOpener.css('color', event.data.color);
529					};
530
531					var originalColor = thisSearchOpener.css('color');
532					var hoverColor = thisSearchOpener.data('hover-color');
533
534					thisSearchOpener.on('mouseenter', {
535						searchOpener: thisSearchOpener,
536						color: hoverColor
537					}, changeSearchColor);
538					thisSearchOpener.on('mouseleave', {
539						searchOpener: thisSearchOpener,
540						color: originalColor
541					}, changeSearchColor);
542				}
543
544			});
545		}
546
547		/**
548	 * Search covers header type of search
549	 */
550		function digiwakeSearchCoversHeader() {
551
552			searchOpener.click(function(e) {
553				e.preventDefault();
554				var searchFormHeight, searchFormHolder = $('.digiwake-search-cover .digiwake-form-holder-outer'), searchFormHolderPosition = $('.digiwake-search-cover .digiwake-form-holder-outer'), searchClose = searchFormHolder.find('.digiwake-search-close'), searchForm = $('.digiwake-search-cover'), searchFormLandmark;
555				// there is one more div element if header is in grid
556
557				if ($(this).closest('.digiwake-grid').length) {
558					searchFormLandmark = searchForm.parent();
559				} else {
560					searchFormLandmark = searchForm;
561				}
562
563				if ($(this).closest('.digiwake-sticky-header').length > 0) {
564					searchFormLandmark = searchForm.parent();
565					searchFormHolderPosition = $(this).closest('.digiwake-sticky-header').find('.digiwake-form-holder-outer');
566				}
567
568				//Find search form position in header and height
569				if (searchFormLandmark.parent().hasClass('digiwake-logo-area')) {
570					searchFormHeight = digiwakeGlobalVars.vars.digiwakeLogoAreaHeight;
571				} else if (searchFormLandmark.parent().hasClass('digiwake-top-bar')) {
572					searchFormHeight = digiwakeGlobalVars.vars.digiwakeTopBarHeight;
573				} else if (searchFormLandmark.parent().hasClass('digiwake-menu-area')) {
574					searchFormHeight = digiwakeGlobalVars.vars.digiwakeMenuAreaHeight - digiwakeGlobalVars.vars.digiwakeTopBarHeight;
575				} else if (searchFormLandmark.hasClass('digiwake-sticky-header')) {
576					searchFormHeight = digiwakeGlobalVars.vars.digiwakeStickyHeaderHeight;
577				} else if (searchFormLandmark.parent().hasClass('digiwake-mobile-header')) {
578					searchFormHeight = $('.digiwake-mobile-header-inner').height();
579				}
580
581				searchFormHolder.height(searchFormHeight);
582				searchForm.stop(true).fadeIn(400, 'easeInOutQuint');
583				searchClose.css({
584					'left': searchOpener.offset().left - searchFormHolderPosition.offset().left + 10,
585					'right': 'auto'
586				});
587				//10px offset adj
588				$('.digiwake-search-cover input[type="text"]').focus();
589				$('.digiwake-search-close, .digiwake-content, footer').click(function(e) {
590					e.preventDefault();
591					searchForm.stop(true).fadeOut(250, 'easeInOutQuint');
592				});
593				searchForm.blur(function() {
594					searchForm.stop(true).fadeOut(250, 'easeInOutQuint');
595				});
596				//Close on escape
597				$(document).keyup(function(e) {
598					if (e.keyCode == 27) {
599						//KeyCode for ESC button is 27
600						searchForm.stop(true).fadeOut(250, 'easeInOutQuint');
601					}
602				});
603			});
604
605		}
606
607		/**
608	 * Fullscreen search (two types: fade and from circle)
609	 */
610		function digiwakeFullscreenSearch(fade, fromCircle) {
611
612			var searchHolder = $('.digiwake-fullscreen-search-holder')
613				, searchOverlay = $('.digiwake-fullscreen-search-overlay');
614
615			searchOpener.click(function(e) {
616				e.preventDefault();
617				var samePosition = false;
618				if ($(this).data('icon-close-same-position') === 'yes') {
619					var closeTop = $(this).offset().top;
620					var closeLeft = $(this).offset().left;
621					samePosition = true;
622				}
623				//Fullscreen search fade
624				if (fade) {
625					if (searchHolder.hasClass('digiwake-animate')) {
626						digiwake.body.removeClass('digiwake-fullscreen-search-opened');
627						digiwake.body.addClass('digiwake-search-fade-out');
628						digiwake.body.removeClass('digiwake-search-fade-in');
629						searchHolder.removeClass('digiwake-animate');
630						if (!digiwake.body.hasClass('page-template-full_screen-php')) {
631							digiwake.modules.common.digiwakeEnableScroll();
632						}
633					} else {
634						digiwake.body.addClass('digiwake-fullscreen-search-opened');
635						digiwake.body.removeClass('digiwake-search-fade-out');
636						digiwake.body.addClass('digiwake-search-fade-in');
637						searchHolder.addClass('digiwake-animate');
638						if (samePosition) {
639							searchClose.css({
640								'top': closeTop - digiwake.scroll,
641								// Distance from top of viewport ( distance from top of window - scroll distance )
642								'left': closeLeft
643							});
644						}
645						if (!digiwake.body.hasClass('page-template-full_screen-php')) {
646							digiwake.modules.common.digiwakeDisableScroll();
647						}
648					}
649					searchClose.click(function(e) {
650						e.preventDefault();
651						digiwake.body.removeClass('digiwake-fullscreen-search-opened');
652						searchHolder.removeClass('digiwake-animate');
653						digiwake.body.removeClass('digiwake-search-fade-in');
654						digiwake.body.addClass('digiwake-search-fade-out');
655						if (!digiwake.body.hasClass('page-template-full_screen-php')) {
656							digiwake.modules.common.digiwakeEnableScroll();
657						}
658					});
659					//Close on escape
660					$(document).keyup(function(e) {
661						if (e.keyCode == 27) {
662							//KeyCode for ESC button is 27
663							digiwake.body.removeClass('digiwake-fullscreen-search-opened');
664							searchHolder.removeClass('digiwake-animate');
665							digiwake.body.removeClass('digiwake-search-fade-in');
666							digiwake.body.addClass('digiwake-search-fade-out');
667							if (!digiwake.body.hasClass('page-template-full_screen-php')) {
668								digiwake.modules.common.digiwakeEnableScroll();
669							}
670						}
671					});
672				}
673				//Fullscreen search from circle
674				if (fromCircle) {
675					if (searchOverlay.hasClass('digiwake-animate')) {
676						searchOverlay.removeClass('digiwake-animate');
677						searchHolder.css({
678							'opacity': 0,
679							'display': 'none'
680						});
681						searchClose.css({
682							'opacity': 0,
683							'visibility': 'hidden'
684						});
685						searchOpener.css({
686							'opacity': 1
687						});
688					} else {
689						searchOverlay.addClass('digiwake-animate');
690						searchHolder.css({
691							'display': 'block'
692						});
693						setTimeout(function() {
694							searchHolder.css('opacity', '1');
695							searchClose.css({
696								'opacity': 1,
697								'visibility': 'visible',
698								'top': closeTop - digiwake.scroll,
699								// Distance from top of viewport ( distance from top of window - scroll distance )
700								'left': closeLeft
701							});
702							if (samePosition) {
703								searchClose.css({
704									'top': closeTop - digiwake.scroll,
705									// Distance from top of viewport ( distance from top of window - scroll distance )
706									'left': closeLeft
707								});
708							}
709							searchOpener.css({
710								'opacity': 0
711							});
712						}, 200);
713						if (!digiwake.body.hasClass('page-template-full_screen-php')) {
714							digiwake.modules.common.digiwakeDisableScroll();
715						}
716					}
717					searchClose.click(function(e) {
718						e.preventDefault();
719						searchOverlay.removeClass('digiwake-animate');
720						searchHolder.css({
721							'opacity': 0,
722							'display': 'none'
723						});
724						searchClose.css({
725							'opacity': 0,
726							'visibility': 'hidden'
727						});
728						searchOpener.css({
729							'opacity': 1
730						});
731						if (!digiwake.body.hasClass('page-template-full_screen-php')) {
732							digiwake.modules.common.digiwakeEnableScroll();
733						}
734					});
735					//Close on escape
736					$(document).keyup(function(e) {
737						if (e.keyCode == 27) {
738							//KeyCode for ESC button is 27
739							searchOverlay.removeClass('digiwake-animate');
740							searchHolder.css({
741								'opacity': 0,
742								'display': 'none'
743							});
744							searchClose.css({
745								'opacity': 0,
746								'visibility': 'hidden'
747							});
748							searchOpener.css({
749								'opacity': 1
750							});
751							if (!digiwake.body.hasClass('page-template-full_screen-php')) {
752								digiwake.modules.common.digiwakeEnableScroll();
753							}
754						}
755					});
756				}
757			});
758
759			//Text input focus change
760			$('.digiwake-fullscreen-search-holder .digiwake-search-field').focus(function() {
761				$('.digiwake-fullscreen-search-holder .digiwake-field-holder .digiwake-line').css("width", "100%");
762			});
763
764			$('.digiwake-fullscreen-search-holder .digiwake-search-field').blur(function() {
765				$('.digiwake-fullscreen-search-holder .digiwake-field-holder .digiwake-line').css("width", "0");
766			});
767
768		}
769
770	}
771}
772)(jQuery);
773
774(function($) {
775	'use strict';
776
777	var common = {};
778	digiwake.modules.common = common;
779
780	common.digiwakeInitBackToTop = digiwakeInitBackToTop;
781	common.digiwakeBackButtonShowHide = digiwakeBackButtonShowHide;
782	common.digiwakeBlogArchive = digiwakeBlogArchive;
783	common.digiwakeInitParallax = digiwakeInitParallax;
784	common.digiwakeSmoothTransition = digiwakeSmoothTransition;
785	common.digiwakePrettyPhoto = digiwakePrettyPhoto;
786
787	common.digiwakeOnDocumentReady = digiwakeOnDocumentReady;
788	common.digiwakeOnWindowLoad = digiwakeOnWindowLoad;
789
790	$(window).load(digiwakeOnWindowLoad);
791	$(document).ready(digiwakeOnDocumentReady);
792
793	function digiwakeOnDocumentReady() {
794		digiwakeInitBackToTop();
795		digiwakeBackButtonShowHide();
796		digiwakeBlogArchive();
797	}
798
799	function digiwakeOnWindowLoad() {
800		digiwakeInitParallax();
801		digiwakeSmoothTransition();
802	}
803
804	function digiwakeToTopButton(a) {
805
806		var b = $("#digiwake-back-to-top");
807		b.removeClass('off on');
808		if (a === 'on') {
809			b.addClass('on');
810		} else {
811			b.addClass('off');
812		}
813	}
814
815	function digiwakeInitParallax() {
816
817		if ($('.digiwake-parallax-section-holder').length) {
818			$('.digiwake-parallax-section-holder').each(function() {
819				var parallaxElement = $(this);
820
821				if (parallaxElement.hasClass('digiwake-full-screen-height-parallax')) {
822					parallaxElement.height(digiwake.windowHeight);
823					parallaxElement.find('.digiwake-parallax-content-outer').css('padding', 0);
824				}
825
826				var speed = parallaxElement.data('digiwake-parallax-speed') * 0.4;
827
828				parallaxElement.parallax("50%", speed);
829			});
830		}
831	}
832
833	function digiwakeSmoothTransition() {
834		var loader = $('body > .digiwake-smooth-transition-loader.digiwake-mimic-ajax');
835		if (loader.length) {
836			loader.find('.digiwake-st-loader1 > div').animate({
837				opacity: 0
838			}, 300, function() {
839				loader.slideUp(1400, 'easeInOutQuint');
840			});
841			$(window).bind("pageshow", function(event) {
842				if (event.originalEvent.persisted) {
843					loader.find('.digiwake-st-loader1 > div').animate({
844						opacity: 0
845					}, 300, function() {
846						loader.slideUp(1400, 'easeInOutQuint');
847					});
848				}
849			});
850
851			$('a').click(function(e) {
852				var a = $(this);
853				if (e.which == 1 && // check if the left mouse button has been pressed
854				a.attr('href').indexOf(window.location.host) >= 0 && // check if the link is to the same domain
855				(typeof a.data('rel') === 'undefined') && //Not pretty photo link
856				(typeof a.attr('rel') === 'undefined') && //Not VC pretty photo link
857				!a.hasClass('digiwake-like') && //Not like link
858				(typeof a.attr('target') === 'undefined' || a.attr('target') === '_self') && // check if the link opens in the same window
859				(a.attr('href').split('#')[0] !== window.location.href.split('#')[0])// check if it is an anchor aiming for a different page
860				) {
861					e.preventDefault();
862					loader.addClass('digiwake-hide-spinner');
863					loader.fadeIn(500, function() {
864						window.location = a.attr('href');
865					});
866				}
867			});
868		}
869	}
870
871	function digiwakeBackButtonShowHide() {
872		digiwake.window.scroll(function() {
873			var b = $(this).scrollTop();
874			var c = $(this).height();
875			var d;
876			if (b > 0) {
877				d = b + c / 2;
878			} else {
879				d = 1;
880			}
881			if (d < 1e3) {
882				digiwakeToTopButton('off');
883			} else {
884				digiwakeToTopButton('on');
885			}
886		});
887	}
888
889	function digiwakeInitBackToTop() {
890		var backToTopButton = $('#digiwake-back-to-top');
891
892		backToTopButton.on('click', function(e) {
893			e.preventDefault();
894			digiwake.html.animate({
895				scrollTop: 0
896			}, digiwake.window.scrollTop() / 2, 'easeInOutCubic');
897		});
898	}
899
900	function digiwakeBlogArchive() {// var navLink = $('.digiwake-blog-category-filter ul li a');
901	}
902
903	function digiwakePrettyPhoto() {
904			/*jshint multistr: true */
905			var markupWhole = '<div class="pp_pic_holder"> \
906											<div class="ppt">&nbsp;</div> \
907											<div class="pp_top"> \
908													<div class="pp_left"></div> \
909													<div class="pp_middle"></div> \
910													<div class="pp_right"></div> \
911											</div> \
912											<div class="pp_content_container"> \
913													<div class="pp_left"> \
914													<div class="pp_right"> \
915															<div class="pp_content"> \
916																	<div class="pp_loaderIcon"></div> \
917																	<div class="pp_fade"> \
918																			<a href="#" class="pp_expand" title="Expand the image">Expand</a> \
919																			<div class="pp_hoverContainer"> \
920																					<a class="pp_next" href="#"><span class="fa fa-angle-right"></span></a> \
921																					<a class="pp_previous" href="#"><span class="fa fa-angle-left"></span></a> \
922																			</div> \
923																			<div id="pp_full_res"></div> \
924																			<div class="pp_details"> \
925																					<div class="pp_nav"> \
926																							<a href="#" class="pp_arrow_previous">Previous</a> \
927																							<p class="currentTextHolder">0/0</p> \
928																							<a href="#" class="pp_arrow_next">Next</a> \
929																					</div> \
930																					<p class="pp_description"></p> \
931																					{pp_social} \
932																					<a class="pp_close" href="#">Close</a> \
933																			</div> \
934																	</div> \
935															</div> \
936													</div> \
937													</div> \
938											</div> \
939											<div class="pp_bottom"> \
940													<div class="pp_left"></div> \
941													<div class="pp_middle"></div> \
942													<div class="pp_right"></div> \
943											</div> \
944									</div> \
945									<div class="pp_overlay"></div>';
946
947		$("a[data-rel^='prettyPhoto']").prettyPhoto({
948			hook: 'data-rel',
949			animation_speed: 'normal', /* fast/slow/normal */
950			slideshow: false, /* false OR interval time in ms */
951			autoplay_slideshow: false, /* true/false */
952			opacity: 0.80, /* Value between 0 and 1 */
953			show_title: true, /* true/false */
954			allow_resize: true, /* Resize the photos bigger than viewport. true/false */
955			horizontal_padding: 0,
956			default_width: 960,
957			default_height: 540,
958			counter_separator_label: '/', /* The separator for the gallery counter 1 "of" 2 */
959			theme: 'pp_default', /* light_rounded / dark_rounded / light_square / dark_square / facebook */
960			hideflash: false, /* Hides all the flash object on a page, set to TRUE if flash appears over prettyPhoto */
961			wmode: 'opaque', /* Set the flash wmode attribute */
962			autoplay: true, /* Automatically start videos: True/False */
963			modal: false, /* If set to true, only the close button will close the window */
964			overlay_gallery: false, /* If set to true, a gallery will overlay the fullscreen image on mouse over */
965			keyboard_shortcuts: true, /* Set to false if you open forms inside prettyPhoto */
966			deeplinking: false,
967			custom_markup: '',
968			social_tools: false,
969			markup: markupWhole
970		});
971	}
972
973	
974}
975)(jQuery);
976
977(function($) {
978	'use strict';
979
980	var shortcodes = {};
981
982	digiwake.modules.shortcodes = shortcodes;
983
984	shortcodes.digiwakeShowGoogleMap = digiwakeShowGoogleMap;
985	shortcodes.digiwakeOnDocumentReady = digiwakeOnDocumentReady;
986
987	$(document).ready(digiwakeOnDocumentReady);
988	$(window).resize(digiwakeOnWindowResize);
989	$(window).load(digiwakeOnWindowLoad);
990
991	/* 
992	All functions to be called on $(document).ready() should be in this function
993	*/
994	function digiwakeOnDocumentReady() {
995		digiwakeInitInstagramSlider();
996		digiwakeButton().init();
997		digiwakeIcon().init();
998		digiwakeInitSpacer();
999		digiwakeInitCustomFont();
1000		digiwakeInitCarousel();
1001		digiwakeInGridColumns();
1002		digiwakeShowGoogleMap();
1003		digiwakeInitProducts();
1004		digiwakeInitBlogs();
1005		digiwakeInitTestimonials();
1006	}
1007
1008	function digiwakeOnWindowLoad() {
1009		digiwakeInitProductSlider();
1010		digiwakeInitBlogSlider();
1011		digiwakeInitTestiSlider();
1012	}
1013
1014	function digiwakeOnWindowResize() {
1015		digiwakeInGridColumns();
1016	}
1017	/**
1018	 * Button object that initializes whole button functionality
1019	 * @type {Function}
1020	 */
1021	var digiwakeButton = digiwake.modules.shortcodes.digiwakeButton = function() {
1022		//all buttons on the page
1023		var buttons = $('.digiwake-btn');
1024
1025		/**
1026		 * Initializes button hover color
1027		 * @param button current button
1028		 */
1029		var buttonHoverColor = function(button) {
1030			if (typeof button.data('hover-color') !== 'undefined') {
1031				var changeButtonColor = function(event) {
1032					event.data.button.css('color', event.data.color);
1033				};
1034
1035				var originalColor = button.css('color');
1036				var hoverColor = button.data('hover-color');
1037
1038				button.on('mouseenter', {
1039					button: button,
1040					color: hoverColor
1041				}, changeButtonColor);
1042				button.on('mouseleave', {
1043					button: button,
1044					color: originalColor
1045				}, changeButtonColor);
1046			}
1047		};
1048
1049		/**
1050		 * Initializes button hover background color
1051		 * @param button current button
1052		 */
1053		var buttonHoverBgColor = function(button, hoverEl) {
1054			if (typeof button.data('hover-bg-color') !== 'undefined') {
1055				var changeButtonBg = function(event) {
1056					event.data.button.css('background-color', event.data.color);
1057				};
1058
1059				var originalBgColor = button.css('background-color');
1060				var hoverBgColor = button.data('hover-bg-color');
1061
1062				if (hoverEl) {
1063					button.find('.digiwake-btn-hover').css('background-color', hoverBgColor);
1064				} else {
1065					button.on('mouseenter', {
1066						button: button,
1067						color: hoverBgColor
1068					}, changeButtonBg);
1069					button.on('mouseleave', {
1070						button: button,
1071						color: originalBgColor
1072					}, changeButtonBg);
1073				}
1074			}
1075		};
1076
1077		/**
1078		 * Initializes button border color
1079		 * @param button
1080		 */
1081		var buttonHoverBorderColor = function(button) {
1082			if (typeof button.data('hover-border-color') !== 'undefined') {
1083				var changeBorderColor = function(event) {
1084					event.data.button.css('border-color', event.data.color);
1085				};
1086
1087				var originalBorderColor = button.css('borderTopColor');
1088				//take one of the four sides
1089				var hoverBorderColor = button.data('hover-border-color');
1090				button.on('mouseenter', {
1091					button: button,
1092					color: hoverBorderColor
1093				}, changeBorderColor);
1094				button.on('mouseleave', {
1095					button: button,
1096					color: originalBorderColor
1097				}, changeBorderColor);
1098			}
1099		};
1100
1101		return {
1102			init: function() {
1103				if (buttons.length) {
1104					buttons.each(function() {
1105						var thisBtn = $(this);
1106						buttonHoverColor(thisBtn);
1107						if (thisBtn.hasClass('digiwake-btn-animated')) {
1108							buttonHoverBgColor(thisBtn, true);
1109						} else {
1110							buttonHoverBgColor(thisBtn, false);
1111							// border color transition exists only for non animated buttons
1112							buttonHoverBorderColor(thisBtn);
1113						}
1114					});
1115				}
1116			}
1117		};
1118	}
1119	;
1120
1121	/**
1122	 * Object that represents icon shortcode
1123	 * @returns {{init: Function}} function that initializes icon's functionality
1124	 */
1125	var digiwakeIcon = digiwake.modules.shortcodes.digiwakeIcon = function() {
1126		//get all icons on page
1127		var icons = $('.digiwake-icon-shortcode');
1128
1129		/**
1130		 * Function that triggers icon animation and icon animation delay
1131		 */
1132		var iconAnimation = function(icon) {
1133			if (icon.hasClass('digiwake-icon-animation')) {
1134				icon.appear(function() {
1135					icon.parent('.digiwake-icon-animation-holder').addClass('digiwake-icon-animation-show');
1136				}, {
1137					accX: 0,
1138					accY: digiwakeGlobalVars.vars.digiwakeElementAppearAmount
1139				});
1140			}
1141		};
1142
1143		/**
1144		 * Function that triggers icon hover color functionality
1145		 */
1146		var iconHoverColor = function(icon) {
1147			if (typeof icon
1147.data('hover-color') !== 'undefined') {
1148				var changeIconColor = function(event) {
1149					event.data.icon.css('color', event.data.color);
1150				};
1151
1152				var iconElement = icon.find('.digiwake-icon-element');
1153				var hoverColor = icon.data('hover-color');
1154				var originalColor = iconElement.css('color');
1155
1156				if (hoverColor !== '') {
1157					icon.on('mouseenter', {
1158						icon: iconElement,
1159						color: hoverColor
1160					}, changeIconColor);
1161					icon.on('mouseleave', {
1162						icon: iconElement,
1163						color: originalColor
1164					}, changeIconColor);
1165				}
1166			}
1167		};
1168
1169		/**
1170		 * Function that triggers icon holder background color hover functionality
1171		 */
1172		var iconHolderBackgroundHover = function(icon) {
1173			if (typeof icon.data('hover-background-color') !== 'undefined') {
1174				var changeIconBgColor = function(event) {
1175					event.data.icon.css('background-color', event.data.color);
1176				};
1177
1178				var hoverBackgroundColor = icon.data('hover-background-color');
1179				var originalBackgroundColor = icon.css('background-color');
1180
1181				if (hoverBackgroundColor !== '') {
1182					icon.on('mouseenter', {
1183						icon: icon,
1184						color: hoverBackgroundColor
1185					}, changeIconBgColor);
1186					icon.on('mouseleave', {
1187						icon: icon,
1188						color: originalBackgroundColor
1189					}, changeIconBgColor);
1190				}
1191			}
1192		};
1193
1194		/**
1195		 * Function that initializes icon holder border hover functionality
1196		 */
1197		var iconHolderBorderHover = function(icon) {
1198			if (typeof icon.data('hover-border-color') !== 'undefined') {
1199				var changeIconBorder = function(event) {
1200					event.data.icon.css('border-color', event.data.color);
1201				};
1202
1203				var hoverBorderColor = icon.data('hover-border-color');
1204				var originalBorderColor = icon.css('border-color');
1205
1206				if (hoverBorderColor !== '') {
1207					icon.on('mouseenter', {
1208						icon: icon,
1209						color: hoverBorderColor
1210					}, changeIconBorder);
1211					icon.on('mouseleave', {
1212						icon: icon,
1213						color: originalBorderColor
1214					}, changeIconBorder);
1215				}
1216			}
1217		};
1218
1219		return {
1220			init: function() {
1221				if (icons.length) {
1222					icons.each(function() {
1223						iconAnimation($(this));
1224						iconHoverColor($(this));
1225						iconHolderBackgroundHover($(this));
1226						iconHolderBorderHover($(this));
1227					});
1228
1229				}
1230			}
1231		};
1232	}
1233	;
1234
1235	/**
1236	 * Initializes Instagram slider
1237	 */
1238	function digiwakeInitInstagramSlider() {
1239		var digiwakeSlider = $('.digiwake-instagram-slider');
1240		if (digiwakeSlider.length) {
1241			digiwakeSlider.each(function() {
1242				var thisDigiwakeSlider = $(this);
1243
1244				thisDigiwakeSlider.on('init', function(slick) {
1245					thisDigiwakeSlider.css('opacity', 1);
1246				});
1247				thisDigiwakeSlider.waitForImages(function() {
1248					var slider_conf = $.parseJSON(thisDigiwakeSlider.closest('.digiwake-instagram-slider-outer').find('.digiwake-instagram-slider-conf').attr('data-conf'));
1249
1250					thisDigiwakeSlider.slick({
1251						dots: (slider_conf.dots) == "true" ? true : false,
1252						infinite: (slider_conf.loop) == "true" ? true : false,
1253						arrows: (slider_conf.arrows) == "true" ? true : false,
1254						speed: parseInt(slider_conf.slidespeed),
1255						autoplay: (slider_conf.autoplay) == "true" ? true : false,
1256						autoplaySpeed: parseInt(slider_conf.playinterval),
1257						slidesToShow: parseInt(slider_conf.slidestoshow),
1258						slidesToScroll: parseInt(slider_conf.slidestoscroll),
1259						responsive: [{
1260							breakpoint: 767,
1261							settings: {
1262								slidesToShow: (parseInt(slider_conf.slidestoshow) > 3) ? 3 : parseInt(slider_conf.slidestoshow),
1263								slidesToScroll: (parseInt(slider_conf.slidestoscroll) > 3) ? 3 : parseInt(slider_conf.slidestoscroll),
1264								infinite: (slider_conf.loop) == "true" ? true : false,
1265								dots: (slider_conf.dots) == "true" ? true : false,
1266							}
1267						}, {
1268							breakpoint: 479,
1269							settings: {
1270								slidesToShow: 2,
1271								slidesToScroll: 2,
1272								dots: false,
1273								infinite: (slider_conf.loop) == "true" ? true : false,
1274							}
1275						}]
1276					});
1277				});
1278			});
1279		}
1280	}
1281
1282	/**
1283	 * Initializes Instagram slider
1284	 */
1285	function digiwakeInitCarousel() {
1286		var digiwakeSlider = $('.digiwake-carousel');
1287		if (digiwakeSlider.length) {
1288			digiwakeSlider.each(function() {
1289				var thisDigiwakeCarousel = $(this);
1290
1291				thisDigiwakeCarousel.on('init', function(slick) {
1292					thisDigiwakeCarousel.css('opacity', 1);
1293				});
1294
1295				var slider_conf = $.parseJSON(thisDigiwakeCarousel.closest('.digiwake-carousel-holder').find('.digiwake-carousel-conf').attr('data-conf'));
1296
1297				var uniqid = thisDigiwakeCarousel.closest('.digiwake-carousel-holder').attr('data-id');
1298				var customCss = '';
1299
1300				if (slider_conf.custom_height && slider_conf.custom_height != '') {
1301					customCss += '.digiwake-carousel-holder-' + uniqid + ' .digiwake-carousel-item{ height: ' + slider_conf.custom_height + '}';
1302				}
1303
1304				if (slider_conf.custom_height_lap && slider_conf.custom_height_lap != '') {
1305					customCss += '@media only screen and (max-width: 1199px) {';
1306					customCss += '.digiwake-carousel-holder-' + uniqid + ' .digiwake-carousel-item{ height: ' + slider_conf.custom_height_lap + '}';
1307					customCss += '}';
1308				}
1309
1310				if (slider_conf.custom_height_tab && slider_conf.custom_height_tab != '') {
1311					customCss += '@media only screen and (max-width: 991px) {';
1312					customCss += '.digiwake-carousel-holder-' + uniqid + ' .digiwake-carousel-item{ height: ' + slider_conf.custom_height_tab + '}';
1313					customCss += '}';
1314				}
1315
1316				if (slider_conf.custom_height_por && slider_conf.custom_height_por != '') {
1317					customCss += '@media only screen and (max-width: 767px) {';
1318					customCss += '.digiwake-carousel-holder-' + uniqid + ' .digiwake-carousel-item{ height: ' + slider_conf.custom_height_por + '}';
1319					customCss += '}';
1320				}
1321
1322				if (slider_conf.dots === 'true' && slider_conf.dots_color !== '' && $('#digiwake_modules-inline-css').size()) {
1323					customCss += '.digiwake-carousel-holder-' + uniqid + ' .slick-dots li.slick-active button, .digiwake-carousel-holder-' + uniqid + ' .slick-dots li button:hover { background-color: ' + slider_conf.dots_color + ' !important}';
1324				}
1325
1326				if (customCss != '') {
1327					$('#digiwake_modules-inline-css').html($('#digiwake_modules-inline-css').html() + customCss);
1328				}
1329
1330				thisDigiwakeCarousel.waitForImages(function() {
1331					thisDigiwakeCarousel.slick({
1332						dots: (slider_conf.dots) === "true",
1333						infinite: (slider_conf.loop) === "true",
1334						arrows: (slider_conf.arrows) === "true",
1335						speed: parseInt(slider_conf.speed),
1336						autoplay: (slider_conf.autoplay) === "true",
1337						autoplaySpeed: parseInt(slider_conf.autoplay_speed),
1338						slidesPerRow: parseInt(slider_conf.slides_on_desk),
1339						rows: 1,
1340						slidesToScroll: slider_conf.slides_to_scroll === 'all' ? parseInt(slider_conf.slides_on_desk) : 1,
1341						swipe: slider_conf.draggable === "true",
1342						draggable: slider_conf.draggable === "true",
1343						touchMove: slider_conf.touchmove === 'true',
1344						lazyLoad: slider_conf.lazyload === 'true',
1345						vertical: slider_conf.type === 'vertical',
1346						pauseOnHover: slider_conf.pauseonhover === 'true',
1347						pauseOnFocus: false,
1348						centerMode: slider_conf.centermode === 'true',
1349						adaptiveHeight: slider_conf.adaptiveheight === 'true',
1350						focusOnSelect: slider_conf.focusonselect === 'true',
1351						nextArrow: $(this).closest('.digiwake-carousel-holder').find('.slick-next'),
1352						prevArrow: $(this).closest('.digiwake-carousel-holder').find('.slick-prev'),
1353						appendDots: $(this).closest('.digiwake-carousel-holder').find('.digiwake-carousel-nav .digiwake-grid'),
1354						responsive: [{
1355							breakpoint: 767,
1356							settings: {
1357								slidesToShow: parseInt(slider_conf.slides_on_tab),
1358								slidesToScroll: slider_conf.slides_to_scroll === 'all' ? parseInt(slider_conf.slides_on_tab) : 1,
1359							}
1360						}, {
1361							breakpoint: 479,
1362							settings: {
1363								slidesToShow: parseInt(slider_conf.slides_on_mob),
1364								slidesToScroll: slider_conf.slides_to_scroll === 'all' ? parseInt(slider_conf.slides_on_mob) : 1,
1365							}
1366						}]
1367					});
1368				});
1369			});
1370		}
1371	}
1372
1373	function digiwakeInitSpacer() {
1374		var css = '';
1375
1376		$('.digiwake-spacer').each(function(i, spacer) {
1377			var uid = $(spacer).data('id');
1378			var height_xs = $(spacer).data('height-xs');
1379			var height_sm = $(spacer).data('height-sm');
1380			var height_lg = $(spacer).data('height-lg');
1381			var height_md = $(spacer).data('height-md');
1382			var height = $(spacer).data('height');
1383
1384			if (typeof height != 'undefined') {
1385				css += '.spacer-' + uid + ' { height:' + height + 'px } ';
1386			}
1387
1388			if (typeof height_lg != 'undefined') {
1389				css += '@media (max-width: 1199px) { .spacer-' + uid + ' { height:' + height_lg + 'px } } ';
1390			}
1391
1392			if (typeof height_md != 'undefined') {
1393				css += '@media (max-width: 991px) { .spacer-' + uid + ' { height:' + height_md + 'px } } ';
1394			}
1395
1396			if (typeof height_sm != 'undefined') {
1397				css += '@media (max-width: 767px) { .spacer-' + uid + ' { height:' + height_sm + 'px } } ';
1398			}
1399
1400			if (typeof height_xs != 'undefined') {
1401				css += '@media (max-width: 479px) { .spacer-' + uid + ' { height:' + height_xs + 'px } } ';
1402			}
1403		});
1404
1405		if (css != '') {
1406			if ($('#digiwake_modules-inline-css').size()) {
1407				var inlineCss = $('#digiwake_modules-inline-css').html();
1408				inlineCss += css;
1409				$('#digiwake_modules-inline-css').html(inlineCss);
1410			}
1411		}
1412	}
1413
1414	function digiwakeInitCustomFont() {
1415		var css = '';
1416
1417		$('.digiwake-custom-font').each(function(i, font) {
1418			var uid = $(font).data('id');
1419			var size = $(font).data('font-size');
1420			var sizeLap = $(font).data('font-size-lap');
1421			var sizeTab = $(font).data('font-size-tab');
1422			var sizeMob = $(font).data('font-size-mob');
1423			var hei = $(font).data('line-height');
1424			var heiLap = $(font).data('line-height-lap');
1425			var heiTab = $(font).data('line-height-tab');
1426			var heiMob = $(font).data('line-height-mob');
1427
1428			if (size && size != '') {
1429				css += '.custom-font-' + uid + ' { font-size:' + size + 'px } ';
1430			}
1431
1432			if (sizeLap && sizeLap != '') {
1433				css += '@media (max-width: 1199px) { .custom-font-' + uid + ' { font-size:' + sizeLap + 'px } } ';
1434			}
1435
1436			if (sizeTab && sizeTab != '') {
1437				css += '@media (max-width: 991px) { .custom-font-' + uid + ' { font-size:' + sizeTab + 'px } } ';
1438			}
1439
1440			if (sizeMob && sizeMob != '') {
1441				css += '@media (max-width: 767px) { .custom-font-' + uid + ' { font-size:' + sizeMob + 'px } } ';
1442			}
1443
1444			if (hei && hei != '') {
1445				css += '.custom-font-' + uid + ' { line-height:' + hei + 'px } ';
1446			}
1447
1448			if (heiLap && heiLap != '') {
1449				css += '@media (max-width: 1199px) { .custom-font-' + uid + ' { line-height:' + heiLap + 'px } } ';
1450			}
1451
1452			if (heiTab && heiTab != '') {
1453				css += '@media (max-width: 991px) { .custom-font-' + uid + ' { line-height:' + heiTab + 'px } } ';
1454			}
1455
1456			if (heiMob && heiMob != '') {
1457				css += '@media (max-width: 767px) { .custom-font-' + uid + ' { line-height:' + heiMob + 'px } } ';
1458			}
1459		});
1460
1461		if (css != '') {
1462			if ($('#digiwake_modules-inline-css').size()) {
1463				var inlineCss = $('#digiwake_modules-inline-css').html();
1464				inlineCss += css;
1465				$('#digiwake_modules-inline-css').html(inlineCss);
1466			}
1467		}
1468	}
1469
1470	function digiwakeInGridColumns() {
1471		$('.vc_row .digiwake-full-section-inner .column-in-grid').each(function(i, column) {
1472			var sectionInnerWid = $(column).closest('.digiwake-full-section-inner').width();
1473			var phSectionWid = $('.digiwake-grid-section.digiwake-placeholder-section .digiwake-section-inner').width();
1474			var offsetWid = (sectionInnerWid - phSectionWid) / 2 - 15;
1475
1476			if ($(window).width() > 767) {
1477				if ($(column).hasClass('column-in-grid-right')) {
1478					$(column).css('padding-left', '');
1479					$(column).css('padding-right', offsetWid + 'px');
1480				} else {
1481					$(column).css('padding-left', offsetWid + 'px');
1482					$(column).css('padding-right', '');
1483				}
1484			} else {
1485				$(column).css('padding-right', offsetWid + 'px');
1486				$(column).css('padding-left', offsetWid + 'px');
1487			}
1488		});
1489
1490		$('.vc_row .digiwake-section-inner-margin .column-out-grid').each(function(i, column) {
1491			if ($(window).width() > 767) {
1492				var sectionInnerWid = $(column).closest('.digiwake-section-inner-margin').width();
1493				var phSectionWid = $('.digiwake-grid-section.digiwake-placeholder-section .digiwake-full-section-inner').width();
1494				var offsetWid = (phSectionWid - sectionInnerWid) / 2;
1495				var remaingWid = sectionInnerWid;
1496
1497				if ($(column).hasClass('column-out-grid-right')) {
1498					$(column).css('margin-left', '');
1499					$(column).css('margin-right', '-' + offsetWid + 'px');
1500
1501					remaingWid -= Math.ceil(parseFloat($(column).css('margin-left')));
1502				} else {
1503					$(column).css('margin-left', '-' + offsetWid + 'px');
1504					$(column).css('margin-right', '');
1505
1506					remaingWid -= $(column).css('margin-right');
1507				}
1508
1509				$(column).siblings().each(function() {
1510					remaingWid -= $(this).width() + 1;
1511				});
1512
1513				$(column).css('width', remaingWid + offsetWid);
1514			} else {
1515				$(column).css('margin-right', '');
1516				$(column).css('margin-left', '');
1517				$(column).css('width', '');
1518			}
1519		});
1520	}
1521
1522	/**
1523	 * Initializes Product slider
1524	 */
1525	function digiwakeInitProducts() {
1526		var css = '';
1527
1528		var productSlider = $('.digiwake-product-slider');
1529
1530		if (productSlider.length) {
1531			productSlider.each(function() {
1532				var thisProductSlider = $(this);
1533				var uniqid = productSlider.data('id');
1534
1535				var width_xs = thisProductSlider.data('width-xs');
1536				var width_sm = thisProductSlider.data('width-sm');
1537				var width_lg = thisProductSlider.data('width-lg');
1538				var width_md = thisProductSlider.data('width-md');
1539				var width = thisProductSlider.data('width');
1540
1541				if (typeof width != 'undefined') {
1542					css += '.digiwake-product-slider-' + uniqid + ' .digiwake-product-carou
1542sel-item{ width:' + width + 'px } ';
1543				}
1544
1545				if (typeof width_lg != 'undefined') {
1546					css += '@media (max-width: 1199px){.digiwake-product-slider-' + uniqid + ' .digiwake-product-carousel-item{ width:' + width_lg + 'px } } ';
1547				}
1548
1549				if (typeof width_md != 'undefined') {
1550					css += '@media (max-width: 991px){.digiwake-product-slider-' + uniqid + ' .digiwake-product-carousel-item{ width:' + width_md + 'px } } ';
1551				}
1552
1553				if (typeof width_sm != 'undefined') {
1554					css += '@media (max-width: 767px){.digiwake-product-slider-' + uniqid + ' .digiwake-product-carousel-item{ width:' + width_sm + 'px } } ';
1555				}
1556
1557				if (typeof width_xs != 'undefined') {
1558					css += '@media (max-width: 479px){.digiwake-product-slider-' + uniqid + ' .digiwake-product-carousel-item{ width:' + width_xs + 'px } } ';
1559				}
1560
1561				if (typeof thisProductSlider.data('spacing') !== 'undefined') {
1562					css += '@media (max-width: 479px){.digiwake-product-slider-' + uniqid + '{';
1563					css += 'margin: 0 -' + (parseInt(thisProductSlider.data('spacing')) / 2) + 'px';
1564					css += '}';
1565					css += '}';
1566					css += '.digiwake-product-slider-' + uniqid + ' .digiwake-product-carousel-item{';
1567					css += 'margin: 0 ' + (parseInt(thisProductSlider.data('spacing')) / 2) + 'px';
1568					css += '}';
1569				}
1570			});
1571		}
1572
1573		if ($('#digiwake_modules-inline-css').size()) {
1574			var inlineCss = $('#digiwake_modules-inline-css').html();
1575			$('#digiwake_modules-inline-css').html(inlineCss + css);
1576		}
1577	}
1578
1579	function digiwakeInitProductSlider() {
1580		var productSlider = $('.digiwake-product-slider');
1581
1582		if (productSlider.length) {
1583			productSlider.each(function() {
1584				var thisProductSlider = $(this);
1585				var options = {
1586					infinite: false,
1587					autoplay: false,
1588					arrows: true,
1589					dots: false,
1590					variableWidth: true,
1591					easing: 'easeOutCubic',
1592				};
1593
1594				if (typeof thisProductSlider.data('arrow-left') !== 'undefined') {
1595					options['prevArrow'] = $(thisProductSlider.data('arrow-left'));
1596				}
1597
1598				if (typeof thisProductSlider.data('arrow-right') !== 'undefined') {
1599					options['nextArrow'] = $(thisProductSlider.data('arrow-right'));
1600				}
1601
1602				thisProductSlider.on('init', function(slick) {
1603					thisProductSlider.css('opacity', 1);
1604				});
1605
1606				thisProductSlider.waitForImages(function() {
1607					thisProductSlider.on('init', function(slick) {
1608						toggleSlickBtns(slick);
1609					});					
1610					thisProductSlider.slick(options);
1611				});
1612
1613			});
1614		}
1615	}
1616
1617	/**
1618	 * Initializes Blog slider
1619	 */
1620	function digiwakeInitBlogs() {
1621		var css = '';
1622
1623		var blogSlider = $('.digiwake-blog-slider');
1624
1625		if (blogSlider.length) {
1626			blogSlider.each(function() {
1627				var thisBlogSlider = $(this);
1628
1629				var uid = thisBlogSlider.data('id');
1630
1631				var width_xs = thisBlogSlider.data('width-xs');
1632				var width_sm = thisBlogSlider.data('width-sm');
1633				var width_lg = thisBlogSlider.data('width-lg');
1634				var width_md = thisBlogSlider.data('width-md');
1635				var width = thisBlogSlider.data('width');
1636
1637				if (typeof thisBlogSlider.data('spacing') !== 'undefined') {
1638					css += '.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{';
1639					css += 'margin: 0 ' + (parseInt(thisBlogSlider.data('spacing')) / 2) + 'px';
1640					css += '}';
1641				}
1642
1643				if (typeof width != 'undefined') {
1644					css += '.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{ width:' + width + 'px } ';
1645				}
1646
1647				if (typeof width_lg != 'undefined') {
1648					css += '@media (max-width: 1199px){.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{ width:' + width_lg + 'px } } ';
1649				}
1650
1651				if (typeof width_md != 'undefined') {
1652					css += '@media (max-width: 991px){.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{ width:' + width_md + 'px } } ';
1653				}
1654
1655				if (typeof width_sm != 'undefined') {
1656					css += '@media (max-width: 767px){.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{ width:' + width_sm + 'px } } ';
1657				}
1658
1659				if (typeof width_xs != 'undefined') {
1660					css += '@media (max-width: 479px){.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{ width:' + width_xs + 'px } } ';
1661				}
1662
1663				if (typeof thisBlogSlider.data('spacing') !== 'undefined') {
1664					css += '.digiwake-blog-slider-' + uid + ' .digiwake-blog-carousel-item{';
1665					css += 'margin: 0 ' + (parseInt(thisBlogSlider.data('spacing')) / 2) + 'px';
1666					css += '}';
1667				}
1668			});
1669		}
1670
1671		if (css != '' && $('#digiwake_modules-inline-css').size()) {
1672			var inlineCss = $('#digiwake_modules-inline-css').html();
1673			$('#digiwake_modules-inline-css').html(inlineCss + css);
1674		}
1675	}
1676
1677	function digiwakeInitBlogSlider() {
1678		var blogSlider = $('.digiwake-blog-slider');
1679
1680		if (blogSlider.length) {
1681			blogSlider.each(function() {
1682				var thisBlogSlider = $(this);
1683
1684				var options = {
1685					infinite: false,
1686					autoplay: false,
1687					variableWidth: true,
1688					arrows: true,
1689					dots: false,
1690					easing: 'easeOutCubic',
1691					responsive: [{
1692						breakpoint: 479,
1693						settings: {
1694							adaptiveHeight: true,
1695							variableWidth: false,
1696						}
1697					}]
1698				};
1699
1700				if (typeof thisBlogSlider.data('arrow-left') !== 'undefined') {
1701					options['prevArrow'] = $(thisBlogSlider.data('arrow-left'));
1702				}
1703
1704				if (typeof thisBlogSlider.data('arrow-right') !== 'undefined') {
1705					options['nextArrow'] = $(thisBlogSlider.data('arrow-right'));
1706				}
1707
1708				thisBlogSlider.on('init', function(slick) {
1709					thisBlogSlider.css('opacity', 1);
1710				});
1711
1712				thisBlogSlider.waitForImages(function() {
1713					thisBlogSlider.on('init', function(slick) {
1714						toggleSlickBtns(slick);
1715					});
1716
1717					thisBlogSlider.slick(options);
1718				});
1719
1720			});
1721		}
1722	}
1723
1724	/**
1725	 * Init testimonials shortcode
1726	 */
1727	function digiwakeInitTestimonials() {
1728		var css = '';
1729
1730		var testimonial = $('.digiwake-testimonials');
1731
1732		if (testimonial.length) {
1733			testimonial.each(function() {
1734
1735				var thisTestimonial = $(this);
1736
1737				var uid = thisTestimonial.data('id');
1738
1739				var width_xs = thisTestimonial.data('width-xs');
1740				var width_sm = thisTestimonial.data('width-sm');
1741				var width_lg = thisTestimonial.data('width-lg');
1742				var width_md = thisTestimonial.data('width-md');
1743				var width = thisTestimonial.data('width');
1744
1745				if (typeof width != 'undefined') {
1746					css += '.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{ width:' + width + 'px } ';
1747				}
1748
1749				if (typeof width_lg != 'undefined') {
1750					css += '@media (max-width: 1199px){.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{ width:' + width_lg + 'px } } ';
1751				}
1752
1753				if (typeof width_md != 'undefined') {
1754					css += '@media (max-width: 991px){.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{ width:' + width_md + 'px } } ';
1755				}
1756
1757				if (typeof width_sm != 'undefined') {
1758					css += '@media (max-width: 767px){.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{ width:' + width_sm + 'px } } ';
1759				}
1760
1761				if (typeof width_xs != 'undefined') {
1762					css += '@media (max-width: 479px){.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{ width:' + width_xs + 'px } } ';
1763				}
1764
1765				if (typeof thisTestimonial.data('spacing') !== 'undefined') {
1766					css += '.digiwake-testi-slider-' + uid + ' .digiwake-testimonial-content{';
1767					css += 'margin: 0 ' + (parseInt(thisTestimonial.data('spacing')) / 2) + 'px';
1768					css += '}';
1769				}
1770			});
1771		}
1772
1773		if (css != '') {
1774			if ($('#digiwake_modules-inline-css').size()) {
1775				var inlineCss = $('#digiwake_modules-inline-css').html();
1776				inlineCss += css;
1777				$('#digiwake_modules-inline-css').html(inlineCss);
1778			}
1779		}
1780	}
1781
1782	function digiwakeInitTestiSlider() {
1783		var testimonial = $('.digiwake-testimonials');
1784
1785		if (testimonial.length) {
1786			testimonial.each(function() {
1787
1788				var thisTestimonial = $(this);
1789
1790				thisTestimonial.waitForImages(function() {
1791					thisTestimonial.css('visibility', 'visible');
1792				});
1793
1794				var options = {
1795					infinite: false,
1796					autoplay: false,
1797					speed: 800,
1798					dots: false,
1799					arrows: true,
1800					slidesToScroll: 1,
1801					variableWidth: true,
1802					dotsClass: 'digiwake-slick-dots',
1803					easing: 'easeOutCubic',
1804					customPaging: function(slider, i) {
1805						return '<span class="digiwake-slick-dot-inner"></span>';
1806					},
1807				};
1808
1809				if (typeof thisTestimonial.data('animation-speed') !== 'undefined' && thisTestimonial.data('animation-speed') !== false) {
1810					options['speed'] = thisTestimonial.data('animation-speed');
1811				}
1812
1813				if (typeof thisTestimonial.data('arrows-navigation') !== 'undefined') {
1814					options['arrows'] = thisTestimonial.data('arrows-navigation');
1815				}
1816
1817				if (typeof thisTestimonial.data('arrow-left') !== 'undefined') {
1818					options['prevArrow'] = $(thisTestimonial.data('arrow-left'));
1819				}
1820
1821				if (typeof thisTestimonial.data('arrow-right') !== 'undefined') {
1822					options['nextArrow'] = $(thisTestimonial.data('arrow-right'));
1823				}
1824
1825				thisTestimonial.on('init', function(slick) {
1826					toggleSlickBtns(slick);
1827				});
1828
1829				thisTestimonial.slick(options);
1830			});
1831		}
1832	}
1833
1834	function toggleSlickBtns(slick) {
1835		var target = $(slick.currentTarget);
1836		var current = target.find('.slick-current');
1837		var slickWid = current.width();
1838
1839		current.nextAll().each(function() {
1840			slickWid += $(this).width() + parseFloat(current.css('margin-left')) + parseFloat(current.css('margin-right'));
1841		});
1842
1843		if(slickWid < target.width()) {
1844			$(target.data('arrow-left')).addClass('slick-hidden').css('display', '');
1845			$(target.data('arrow-right')).addClass('slick-hidden').css('display', '');
1846		}
1847	}
1848
1849	/*
1850	 ** Show Google Map
1851	 */
1852	function digiwakeShowGoogleMap() {
1853
1854		if ($('.digiwake-google-map').length) {
1855			$('.digiwake-google-map').each(function() {
1856
1857				var element = $(this);
1858
1859				var customMapStyle;
1860				if (typeof element.data('custom-map-style') !== 'undefined') {
1861					customMapStyle = element.data('custom-map-style');
1862				}
1863
1864				var colorOverlay;
1865				if (typeof element.data('color-overlay') !== 'undefined' && element.data('color-overlay') !== false) {
1866					colorOverlay = element.data('color-overlay');
1867				}
1868
1869				var saturation;
1870				if (typeof element.data('saturation') !== 'undefined' && element.data('saturation') !== false) {
1871					saturation = element.data('saturation');
1872				}
1873
1874				var lightness;
1875				if (typeof element.data('lightness') !== 'undefined' && element.data('lightness') !== false) {
1876					lightness = element.data('lightness');
1877				}
1878
1879				var zoom;
1880				if (typeof element.data('zoom') !== 'undefined' && element.data('zoom') !== false) {
1881					zoom = element.data('zoom');
1882				}
1883
1884				var pin;
1885				if (typeof element.data('pin') !== 'undefined' && element.data('pin') !== false) {
1886					pin = element.data('pin');
1887				}
1888
1889				var mapHeight;
1890				if (typeof element.data('height') !== 'undefined' && element.data('height') !== false) {
1891					mapHeight = element.data('height');
1892				}
1893
1894				var uniqueId;
1895				if (typeof element.data('unique-id') !== 'undefined' && element.data('unique-id') !== false) {
1896					uniqueId = element.data('unique-id');
1897				}
1898
1899				var scrollWheel;
1900				if (typeof element.data('scroll-wheel') !== 'undefined') {
1901					scrollWheel = element.data('scroll-wheel');
1902				}
1903				var addresses;
1904				if (typeof element.data('addresses') !== 'undefined' && element.data('addresses') !== false) {
1905					addresses = element.data('addresses');
1906				}
1907
1908				var map = "map_" + uniqueId;
1909				var geocoder = "geocoder_" + uniqueId;
1910				var holderId = "digiwake-map-" + uniqueId;
1911
1912				digiwakeInitializeGoogleMap(customMapStyle, colorOverlay, saturation, lightness, scrollWheel, zoom, holderId, mapHeight, pin, map, geocoder, addresses);
1913			});
1914		}
1915	}
1916
1917	/*
1918	 ** Init Google Map
1919	 */
1920	function digiwakeInitializeGoogleMap(customMapStyle, color, saturation, lightness, wheel, zoom, holderId, height, pin, map, geocoder, data) {
1921
1922		var mapStyles = [{
1923			stylers: [{
1924				hue: color
1925			}, {
1926				saturation: saturation
1927			}, {
1928				lightness: lightness
1929			}, {
1930				gamma: 1
1931			}]
1932		}];
1933
1934		var googleMapStyleId;
1935
1936		if (customMapStyle) {
1937			googleMapStyleId = 'digiwake-style';
1938		} else {
1939			googleMapStyleId = google.maps.MapTypeId.ROADMAP;
1940		}
1941
1942		var qoogleMapType = new google.maps.StyledMapType(mapStyles,{
1943			name: "Edge Google Map"
1944		});
1945
1946		geocoder = new google.maps.Geocoder();
1947		var latlng = new google.maps.LatLng(-34.397,150.644);
1948
1949		if (!isNaN(height)) {
1950			height = height + 'px';
1951		}
1952
1953		var myOptions = {
1954
1955			zoom: zoom,
1956			scrollwheel: wheel,
1957			center: latlng,
1958			zoomControl: true,
1959			zoomControlOptions: {
1960				style: google.maps.ZoomControlStyle.SMALL,
1961				position: google.maps.ControlPosition.RIGHT_CENTER
1962			},
1963			scaleControl: false,
1964			scaleControlOptions: {
1965				position: google.maps.ControlPosition.LEFT_CENTER
1966			},
1967			streetViewControl: false,
1968			streetViewControlOptions: {
1969				position: google.maps.ControlPosition.LEFT_CENTER
1970			},
1971			panControl: false,
1972			panControlOptions: {
1973				position: google.maps.ControlPosition.LEFT_CENTER
1974			},
1975			mapTypeControl: false,
1976			mapTypeControlOptions: {
1977				mapTypeIds: [google.maps.MapTypeId.ROADMAP, 'digiwake-style'],
1978				style: google.maps.MapTypeControlStyle.HORIZONTAL_BAR,
1979				position: google.maps.ControlPosition.LEFT_CENTER
1980			},
1981			mapTypeId: googleMapStyleId
1982		};
1983
1984		map = new google.maps.Map(document.getElementById(holderId),myOptions);
1985		map.mapTypes.set('digiwake-style', qoogleMapType);
1986
1987		var index;
1988
1989		for (index = 0; index < data.length; ++index) {
1990			digiwakeInitializeGoogleAddress(data[index], pin, map, geocoder);
1991		}
1992
1993		var holderElement = document.getElementById(holderId);
1994		holderElement.style.height = height;
1995	}
1996
1997	/*
1998	 ** Init Google Map Addresses
1999	 */
2000	function digiwakeInitializeGoogleAddress(data, pin, map, geocoder) {
2001		if (data === '')
2002			return;
2003		var contentString = '<div id="content">' + '<div id="siteNotice">' + '</div>' + '<div id="bodyContent">' + '<p>' + data + '</p>' + '</div>' + '</div>';
2004		var infowindow = new google.maps.InfoWindow({
2005			content: contentString
2006		});
2007		geocoder.geocode({
2008			'address': data
2009		}, function(results, status) {
2010			if (status === google.maps.GeocoderStatus.OK) {
2011				map.setCenter(results[0].geometry.location);
2012				var marker = new google.maps.Marker({
2013					map: map,
2014					position: results[0].geometry.location,
2015					icon: pin,
2016					title: data['store_title']
2017				});
2018				google.maps.event.addListener(marker, 'click', function() {
2019					infowindow.open(map, marker);
2020				});
2021
2022				google.maps.event.addDomListener(window, 'resize', function() {
2023					map.setCenter(results[0].geometry.location);
2024				});
2025			}
2026		});
2027	}
2028}
2029)(jQuery);
2030
2031(function($) {
2032	'use strict';
2033
2034	var woocommerce = {};
2035	digiwake.modules.woocommerce = woocommerce;
2036
2037	woocommerce.digiwakeInitQuantityButtons = digiwakeInitQuantityButtons;
2038	woocommerce.digiwakeInitSelect2 = digiwakeInitSelect2;
2039	woocommerce.digiwakeInitSingleProductLightbox = digiwakeInitSingleProductLightbox;
2040
2041	woocommerce.digiwakeOnDocumentReady = digiwakeOnDocumentReady;
2042	woocommerce.digiwakeOnWindowLoad = digiwakeOnWindowLoad;
2043	woocommerce.digiwakeOnWindowResize = digiwakeOnWindowResize;
2044	woocommerce.digiwakeOnWindowScroll = digiwakeOnWindowScroll;
2045
2046	$(document).ready(digiwakeOnDocumentReady);
2047	$(window).load(digiwakeOnWindowLoad);
2048	$(window).resize(digiwakeOnWindowResize);
2049	$(window).scroll(digiwakeOnWindowScroll);
2050
2051	/* 
2052		All functions to be called on $(document).ready() should be in this function
2053	*/
2054	function digiwakeOnDocumentReady() {
2055		digiwakeInitQuantityButtons();
2056		digiwakeInitSelect2();
2057		digiwakeAddedToCartButton();
2058		digiwakeInitSingleProductLightbox();
2059	}
2060
2061	/* 
2062		All functions to be called on $(window).load() should be in this function
2063	*/
2064	function digiwakeOnWindowLoad() {
2065	}
2066
2067	/* 
2068		All functions to be called on $(window).resize() should be in this function
2069	*/
2070	function digiwakeOnWindowResize() {
2071	}
2072
2073	/* 
2074		All functions to be called on $(window).scroll() should be in this function
2075	*/
2076	function digiwakeOnWindowScroll() {
2077	}
2078
2079	function digiwakeInitQuantityButtons() {
2080
2081		$(document).on('click', '.digiwake-quantity-minus, .digiwake-quantity-plus', function(e) {
2082			e.stopPropagation();
2083
2084			var button = $(this), inputField = button.parents('.digiwake-quantity-buttons').find('.digiwake-quantity-input'), step = parseFloat(inputField.attr('step')), max = parseFloat(inputField.attr('max')), minus = false, inputValue = parseFloat(inputField.val()), newInputValue;
2085
2086			if (button.hasClass('digiwake-quantity-minus')) {
2087				minus = true;
2088			}
2089
2090			if (minus) {
2091				newInputValue = inputValue - step;
2092				if (newInputValue >= 1) {
2093					inputField.val(newInputValue);
2094				} else {
2095					inputField.val(1);
2096				}
2097			} else {
2098				newInputValue = inputValue + step;
2099				if (max === undefined) {
2100					inputField.val(newInputValue);
2101				} else {
2102					if (newInputValue >= max) {
2103						inputField.val(max);
2104					} else {
2105						inputField.val(newInputValue);
2106					}
2107				}
2108			}
2109
2110			inputField.trigger('change');
2111
2112		});
2113
2114	}
2115
2116	function digiwakeInitSelect2() {
2117
2118		if ($('.woocommerce-ordering .orderby').length || $('#calc_shipping_country').length) {
2119
2120			$('.woocommerce-ordering .orderby').select2({
2121				minimumResultsForSearch: Infinity
2122			});
2123
2124			$('#calc_shipping_country, .dropdown_product_cat, .dropdown_layered_nav_color').select2();
2125
2126		}
2127
2128	}
2129
2130	function digiwakeAddedToCartButton() {
2131		$('body').on("added_to_cart", function(data) {
2132
2133			var btn = $('a.added_to_cart:not(.digiwake-btn)');
2134			btn.addClass('digiwake-btn').html("<span class='digiwake-icon-font-elegant icon_check'></span><span class='digiwake-btn-text'>" + btn.html() + "</span>");
2135		});
2136	}
2137
2138	/*
2139	 ** Init Product Single Pretty Photo attributes
2140	 */
2141	function digiwakeInitSingleProductLightbox() {
2142
2143		var item = $('.digiwake-woocommerce-single-page .digiwake-single-product-images .images .woocommerce-product-gallery__image a');
2144
2145		if (item.length) {
2146			item.each(function() {
2147				var thisItem = $(this);
2148
2149				thisItem.attr('data-rel', 'prettyPhoto[woo_single_pretty_photo]');
2150
2151				if (typeof digiwake.modules.common.digiwakePrettyPhoto === "function") {
2152					digiwake.modules.common.digiwakePrettyPhoto();
2153				}
2154			});
2155		}
2156	}
2157
2158}
2159)(jQuery);

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.