PageSourceSearch

https://www.safetyshoesfactory.com/themes/zzx/professionalto/static/js/theme.js

js safetyshoesfactory.com collected 2026-10-04 04:56:50 UTC 4,211 bytes, 188 lines download raw bytes

1(function() {
2
3	"use strict";
4
5	var Core = {
6
7		initialized: false,
8
9		initialize: function() {
10
11			if (this.initialized) return;
12			this.initialized = true;
13
14			this.build();
15
16		},
17
18		build: function() {
19
20			//Placeholder for IE
21			// $('input, textarea').placeholder();
22			
23			// Dropdown menu
24			this.dropdownhover();
25			
26			// Page preloader
27			this.initPagePreloader();
28			
29
30			
31			//Setup WOW.js
32			// this.initScrollAnimations();
33
34			
35			// Tabs
36			this.initTabs();
37			
38			// Collapse Blocks
39			this.initCollapsible();
40			
41			// Counter
42			this.initNumberCounter();
43			
44			
45			
46			// Isotope
47			this.initIsotope();
48			
49
50			
51		},
52
53		dropdownhover: function(options) {
54			/** Extra script for smoother navigation effect **/
55			if ($(window).width() > 767) {
56				$('.navbar-main-slide').on('mouseenter', '.navbar-nav-menu > .dropdown', function() {
57					"use strict";
58					$(this).addClass('open');
59				}).on('mouseleave', '.navbar-nav-menu > .dropdown', function() {
60					"use strict";
61					$(this).removeClass('open');
62				});
63			}
64		},
65
66		initPagePreloader: function(options) {
67			var $preloader = $('#page-preloader'),
68			$spinner = $preloader.find('.spinner-loader');
69			$( window ).on(function() {
70				$spinner.fadeOut();
71				$preloader.delay(500).fadeOut('slow');
72				window.scrollTo( 0, 0 );
73			});
74		},
75
76
77		initScrollAnimations: function(options) {
78			var scrollingAnimations = true; // Set true for turn on animation
79			if(scrollingAnimations){
80				new WOW().init();
81			}
82		},
83
84		
85
86		
87		initTabs: function(options) {
88			$(document).on('click', '.js-tab-link', function(e){
89				var tabId = $(this).data('for');
90				var tabContainer = $(tabId);
91				if(tabContainer.length > 0){
92					$('.js-tab-link').removeClass('aside-tabs__active-link');
93					$(this).addClass('aside-tabs__active-link');
94					$('.js-tab-block').hide();
95					tabContainer.show();
96				}
97				e.preventDefault();
98			});
99		},
100		
101		initCollapsible: function(options) {
102			var collapse = $('.js-toggle').length;
103			if(collapse){
104				$(document).on('click', '.js-toggle', function(e){
105					$(this).find('span').toggleClass('fa-plus fa-minus');
106					$(this).parents('.services__info-block').toggleClass('services__info-block--active');
107					e.preventDefault();
108				});
109			}
110		},
111		
112		initNumberCounter: function(options) {
113			if ($('body').length) {
114				var waypointScroll = $('.percent-blocks').data('waypoint-scroll');
115				if(waypointScroll){
116					$(window).on('scroll', function() {
117						var winH = $(window).scrollTop();
118						$('.percent-blocks').waypoint(function() {
119							$('.chart').each(function() {
120								CharsStart();
121							});
122						}, {
123							offset: '80%'
124						});
125					});
126				}
127			}
128			function CharsStart() {
129				$('.chart').easyPieChart({
130					barColor: false,
131					trackColor: false,
132					scaleColor: false,
133					scaleLength: false,
134					lineCap: false,
135					lineWidth: false,
136					size: false,
137					animate: 3000,
138					onStep: function(from, to, percent){
139						$(this.el).find('.percent').text(Math.round(percent));
140					}
141				});
142			}
143		},
144
145	
146
147		initIsotope: function(options) {
148			var $isotopeContainer = $('.isotope');
149			if($isotopeContainer && $isotopeContainer.length){
150				var $container = $('.isotope');
151				$(document).on('click', '.js-isotope-btn', function(){
152					$('.js-isotope-btn').removeClass('button--active');
153					$(this).addClass('button--active');
154					
155					var sortName = $(this).data('sort-by');
156
157					$container.isotope({ 
158						sortBy : sortName,
159					});
160					return false;
161				});
162
163				$container.isotope({
164					itemSelector : '.isotope-item',
165					getSortData : {
166						name: '.name',
167					}
168				});
169			}
170		},
171
172		
173		initSearchModal: function(options) {
174			$(document).on("click", ".btn_header_search", function (event) {
175				event.preventDefault();
176				$(".search-form-modal").addClass("open");
177			});
178			$(document).on("click", ".search-form_close", function (event) {
179				event.preventDefault();
180				$(".search-form-modal").removeClass("open");
181			});
182		},
183		
184	};
185
186	Core.initialize();
187
188})();

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.