PageSourceSearch

https://biletnikoffaward.com/wp-content/themes/Karma/truethemes_framework/js/truethemes.js?ver=2.0

js biletnikoffaward.com collected 2026-10-02 10:19:29 UTC 11,488 bytes, 416 lines download raw bytes

1/*------------------------------------------------*/
2/*	Fire up functions on Page load
3/*------------------------------------------------*/
4jQuery(document).ready(function () {
5  ttMobileMenu();
6  NavSetup();
7  initNav();
8  jQuery("#menu-main-nav li:has(ul)").addClass("parent");
9  iex();
10  initScrollTop();
11  //since version 3.0.2, removed old tabs init code and replace with following function.
12  initTabs();
13  jQuery("ul.products .product").find('br').remove();
14});
15
16
17/*----------------------*/
18/* Tabs
19/*----------------------*/
20function initTabs(){
21  
22  //Added since 3.0.2 dev 4. 
23  //tabs init code, added with browser url sniff to get tab id to allow activating tab via link
24  //example url http://localhost:8888/karma-experimental/shortcodes/tabs-accordion/?tab=2
25  
26  var tab_id = window.location.search.split('?tab='); //find ?tab=2 in browser url.
27	      if(tab_id){ //if there is tab id found. We use tab_id[1], which is the number.
28	        var tab_index = tab_id[1]-1; //minus by 1, so as to get the tab index which starts from 0
29			jQuery( '.tabs-area' ).tabs({ fx: { opacity: 'toggle' },selected:tab_index}); //assign tab index to init code
30	      }else{
31	        //if there is no tab id found in browser url, we set it to 0, which is the first tab
32  			jQuery( '.tabs-area' ).tabs({ fx: { opacity: 'toggle' },selected:0});	      
33	      }  
34
35}
36
37
38/*------------------------------------------------*/
39/*	Main Navigation
40/*------------------------------------------------*/
41function NavSetup() {
42var mainNav = jQuery('#menu-main-nav');
43    var lis = mainNav.find('li');
44    var shownav = jQuery("#menu-main-nav");
45    lis.children('ul').wrap('<div class="c" / >');
46    var cElems = jQuery('.c');
47    cElems.wrap('<div class="drop" / >');
48    cElems.before('<div class="t"></div>');
49    cElems.after('<div class="b"></div>');
50    jQuery(shownav).find(".sub-menu").css({
51      display: "block"
52    });
53}
54
55function initNav() {
56  var nav = jQuery("#menu-main-nav");
57  var duration = 260;
58  jQuery(nav).find(".sub-menu").css({
59    left: 0
60  });
61  jQuery(nav).find("> li").each(function () {
62    var height = jQuery(this).find("> .drop").height();
63    jQuery(this).find("> .drop").css({
64      display: "none",
65      height: 0,
66      overflow: "hidden"
67    });
68    jQuery(this).find(".drop li > .drop").css({
69      display: "none",
70      width: 0
71    });
72    if (!jQuery.browser.msie) {
73      jQuery(this).find("> .drop").css({
74        "opacity": 0
75      });
76      jQuery(this).find(".drop li > .drop").css({
77        "opacity": 0
78      })
79    }
80    jQuery(this).mouseenter(function () {
81      jQuery(this).addClass("hover");
82      var drop = jQuery(this).find("> .drop");
83      if (jQuery.browser.msie) {
84        jQuery(drop).css({
85          display: "block"
86        }).stop().animate({
87          "height": height
88        }, duration, function () {
89          jQuery(this).css({
90            "overflow": "visible"
91          })
92        })
93      }
94      else {
95        jQuery(drop).css({
96          display: "block"
97        }).stop().animate({
98          "height": height,
99          "opacity": 1
100        }, duration, function () {
101          jQuery(this).css({
102            "overflow": "visible"
103          })
104        })
105      }
106    }).mouseleave(function () {
107      var _this = jQuery(this);
108      if (jQuery.browser.msie) {
109        jQuery(this).find("> .drop").stop().css({
110          "overflow": "hidden"
111        }).animate({
112          "height": 0
113        }, duration, function () {
114          jQuery(_this).removeClass("hover")
115        })
116      }
117      else {
118        jQuery(this).find("> .drop").stop().css({
119          "overflow": "hidden"
120        }).animate({
121          "height": 0,
122          "opacity": 0
123        }, duration, function () {
124          jQuery(_this).removeClass("hover")
125        })
126      }
127    });
128    jQuery(this).find(".drop ul > li ").mouseenter(function () {
129      jQuery(this).addClass("hover");
130      var pageW = getPageSize()[2];
131      if (pageW < jQuery(this).offset().left + 236 * 2) {
132        jQuery(this).find("> .drop").css({
133          left: 'auto',
134          right: 236
135        })
136      }
137      if (jQuery.browser.msie) {
138        jQuery(this).find("> .drop").css({
139          display: 'block'
140        }).stop().animate({
141          "width": 236
142        }, duration, function () {
143          jQuery(this).css({
144            overflow: 'visible'
145          })
146        })
147      }
148      else {
149        jQuery(this).find("> .drop").css({
150          display: 'block'
151        }).stop().animate({
152          "width": 236,
153          "opacity": 1
154        }, duration, function () {
155          jQuery(this).css({
156            overflow: 'visible'
157          })
158        })
159      }
160    }).mouseleave(function () {
161      jQuery(this).removeClass("hover");
162      if (jQuery.browser.msie) {
163        jQuery(this).find("> .drop").stop().css({
164          overflow: 'hidden'
165        }).animate({
166          width: 0
167        }, duration, function () {
168          jQuery(this).css({
169            display: 'none'
170          })
171        })
172      }
173      else {
174        jQuery(this).find("> .drop").stop().css({
175          overflow: 'hidden'
176        }).animate({
177          width: 0,
178          "opacity": 0
179        }, duration, function () {
180          jQuery(this).css({
181            display: 'none'
182          })
183        })
184      }
185    })
186  })
187}
188
189function getPageSize() {
190  var xScroll, yScroll;
191  if (window.innerHeight && window.scrollMaxY) {
192    xScroll = document.body.scrollWidth;
193    yScroll = window.innerHeight + window.scrollMaxY
194  }
195  else if (document.body.scrollHeight > document.body.offsetHeight) {
196    xScroll = document.body.scrollWidth;
197    yScroll = document.body.scrollHeight
198  }
199  else if (document.documentElement && document.documentElement.scrollHeight > document.documentElement.offsetHeight) {
200    xScroll = document.documentElement.scrollWidth;
201    yScroll = document.documentElement.scrollHeight
202  }
203  else {
204    xScroll = document.body.offsetWidth;
205    yScroll = document.body.offsetHeight
206  }
207  var windowWidth, windowHeight;
208  if (self.innerHeight) {
209    windowWidth = self.innerWidth;
210    windowHeight = self.innerHeight
211  }
212  else if (document.documentElement && document.documentElement.clientHeight) {
213    windowWidth = document.documentElement.clientWidth;
214    windowHeight = document.documentElement.clientHeight
215  }
216  else if (document.body) {
217    windowWidth = document.body.clientWidth;
218    windowHeight = document.body.clientHeight
219  }
220  if (yScroll < windowHeight) {
221    pageHeight = windowHeight
222  }
223  else {
224    pageHeight = yScroll
225  }
226  if (xScroll < windowWidth) {
227    pageWidth = windowWidth
228  }
229  else {
230    pageWidth = xScroll
231  }
232  return [pageWidth, pageHeight, windowWidth, windowHeight]
233}
234
235
236/*------------------------------------------------*/
237/*	Portfolio Image Fade
238/*------------------------------------------------*/
239(function (jQuery) {
240  jQuery(window).load(function () {
241
242    jQuery('[class^="attachment"]').each(function (index) {
243      var t = jQuery('[class^="attachment"]').length;
244      if (t > 0) { // if there is image length, we fade in
245        jQuery(this).delay(400 * index).fadeIn(500);
246      }
247    });
248
249  });
250})(jQuery);
251
252
253/*------------------------------------------------*/
254/*	Portfolio Image Hover
255/*------------------------------------------------*/
256(function (jQuery) {
257  jQuery(document).ready(function () {
258    jQuery('.preload').hover(function () {
259      jQuery(this).children().first().children().first().stop(true);
260      jQuery(this).children().first().children().first().fadeTo('normal', .90)
261    }, function () {
262      jQuery(this).children().first().children().first().stop(true);
263      jQuery(this).children().first().children().first().fadeTo('normal', 0)
264    })
265  })
266})(jQuery);
267
268
269/*------------------------------------------------*/
270/*	Button Hover
271/*------------------------------------------------*/
272if (jQuery.browser.msie) { /* time to download a new browser */
273}
274else {
275  jQuery(document).ready(function () {
276    jQuery(".ka_button, #ka-submit, #searchform #searchsubmit, .ka-form-submit, #mc_signup #mc_signup_submit, .fade-me").hover(function () {
277      jQuery(this).stop().animate({
278        opacity: 0.7
279      }, 250)
280    }, function () {
281      jQuery(this).stop().animate({
282        opacity: 1.0
283      }, 250)
284    })
285  });
286  jQuery(document).ready(function () {
287    jQuery(".social_icons a").hover(function () {
288      jQuery(this).stop().animate({
289        opacity: 0.65
290      }, 200)
291    }, function () {
292      jQuery(this).stop().animate({
293        opacity: 1
294      }, 200)
295    })
296  });
297}
298
299
300/*------------------------------------------------*/
301/*	Scroll to Top
302/*------------------------------------------------*/
303
304function initScrollTop() {
305  var change_speed = 1200;
306  jQuery('a.link-top').click(function () {
307    if (!jQuery.browser.opera) {
308      jQuery('body').animate({
309        scrollTop: 0
310      }, {
311        queue: false,
312        duration: change_speed
313      })
314    }
315    jQuery('html').animate({
316      scrollTop: 0
317    }, {
318      queue: false,
319      duration: change_speed
320    });
321    return false
322  })
323}
324
325
326/*------------------------------------------------*/
327/*  Mobile Menu
328/*------------------------------------------------*/
329function ttMobileMenu() {
330  var mobileMenuClone = jQuery('#menu-main-nav').clone().attr('id', 'tt-mobile-menu-list');
331 
332  function ttMobileMenu() {
333    var windowWidth = jQuery(window).width();
334 
335    if (windowWidth <= 775) {
336      if (!jQuery('#tt-mobile-menu-button').length) {
337        jQuery('<a id="tt-mobile-menu-button" href="#tt-mobile-menu-list"><span></span></a>').prependTo('#header');
338        mobileMenuClone.insertAfter('#tt-mobile-menu-button').wrap('<div id="tt-mobile-menu-wrap" />');
339        tt_menu_listener();
340      }else{
341                jQuery('#tt-mobile-menu-button').css('display', 'block');
342            }
343    }
344    else {
345            jQuery('#tt-mobile-menu-button').css('display', 'none');
346      mobileMenuClone.css('display', 'none');
347    }
348  }
349  ttMobileMenu();
350 
351  function tt_menu_listener() {
352    jQuery('#tt-mobile-menu-button').click(function (e) {
353      if (jQuery('body').hasClass('ie8')) {
354 
355        var mobileMenu = jQuery('#tt-mobile-menu-list');
356 
357        if (mobileMenu.css('display') === 'block') {
358          mobileMenu.css({
359            'display': 'none'
360          });
361        }
362        else {
363          var mobileMenu = jQuery('#tt-mobile-menu-list');
364          mobileMenu.css({
365            'display': 'block',
366            'height': 'auto',
367            'z-index': 999,
368            'position': 'absolute'
369          });
370        }
371 
372      }
373      else {
374 
375        jQuery('#tt-mobile-menu-list').stop().slideToggle(500);
376 
377      }
378 
379      e.preventDefault();
380    });
381 
382    jQuery('#tt-mobile-menu-list').find('> .menu-item').each(function(){
383 
384      var $this = jQuery(this),
385        opener = $this.find('> a'),
386        slide = $this.find('> .sub-menu');
387 
388    })
389  }
390 
391  jQuery(window).resize(function () {
392    ttMobileMenu();
393  });
394 
395  jQuery(window).load(function(){
396      jQuery('#tt-mobile-menu-list').hide();
397   });
398 
399  jQuery(document).ready(function(){
400      jQuery('#tt-mobile-menu-list').hide();
401   });  
402 
403}
404
405
406
407/*------------------------------------------------*/
408/*	IE
409/*------------------------------------------------*/
410function iex() {
411  if (jQuery.browser.msie || jQuery.browser.opera) {
412    jQuery(window).load(function () {
413      jQuery('.big-banner #main .main-area').css("padding-top", "118px");
414    });
415  }
416}

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.