PageSourceSearch

https://bellinghambjj.com/wp-content/themes/aza-lite/js/script.js?ver=1.0.0

js bellinghambjj.com collected 2026-10-08 10:31:12 UTC 3,140 bytes, 101 lines download raw bytes

1/*=============================
2 =========== JS CHECK  =========
3 ===============================*/
4
5jQuery('html').removeClass('no-js');
6jQuery('html').addClass('js');
7
8jQuery(document).ready(function ($) {
9    windowWidth = $(window).width();
10    if (windowWidth >= 768) {
11        centerMenu();
12    }
13    /*=============================
14     ======= PRELOADER SCRIPT ======
15     ===============================*/
16    setTimeout(function () {
17        $('body').addClass('loaded');
18
19    }, 1000);
20
21    /*=============================
22     ========= MAP OVERLAY =========
23     ===============================*/
24
25    $('.map_overlay').click(function(){
26        $(this).hide();
27    });
28
29    var buttons = $('#pirate-forms-contact-submit, .wpcf7-form input.wpcf7-submit');
30    if ( buttons !== undefined ) {
31        buttons.addClass('btn btn-default');
32    }
33
34    /*=============================
35     ========= Smooth scr =========
36     ===============================*/
37
38    $( '.navbar a[href*="#"], a.btn[href*="#"]' ).click(function () {
39        var menuitem = $(this).attr( 'class' );
40        if (menuitem === 'dropdown-toggle' ) {
41            return;
42        }
43        if (location.pathname.replace(/^\//, '' ) === this.pathname.replace(/^\//, '' ) && location.hostname === this.hostname) {
44            var target = $(this.hash);
45            target = target.length ? target : $( '[name=' + this.hash.slice(1) + ']' );
46            if (target.length) {
47                $( 'html,body' ).animate({
48                    scrollTop: target.offset().top
49                }, 1200 );
50                return false;
51            }
52        }
53    });
54
55    /*=============================
56     ========= Center Menu =========
57     ===============================*/
58    function centerMenu() {
59        var primaryMenu = $('.navbar-nav');
60        var navbarBrand = $('.navbar-brand');
61        var titleTagline = $('.title-tagline-wrapper');
62        var container = $('.navbar>.container');
63
64        if ( ( primaryMenu.width() + navbarBrand.width() >= container.width() ) || ( primaryMenu.width() + titleTagline.width() >= container.width() ) ) {
65            container.addClass('centered-menu');
66        } else {
67            container.removeClass('centered-menu');
68        }
69    }
70
71    $(window).resize(function() {
72        if (windowWidth >= 768) {
73        if(this.resizeTO) clearTimeout(this.resizeTO);
74        this.resizeTO = setTimeout(function() {
75            $(this).trigger('resizeEnd');
76        }, 100);
77    }});
78    $(window).bind('resizeEnd', function() {
79        centerMenu();
80    });
81
82    var stickyNavbar = $('.sticky-navbar');
83    if( stickyNavbar.length !== 0 ) {
84        var atTop = true;
85        $(window).scroll (function () {
86            if ($(document).scrollTop() > 200) {
87                if (atTop) {
88                    atTop = false;
89                    $( '.sticky-navbar' ).addClass( 'navbar-small' );
90                }
91            } else {
92                if (!atTop) {
93                    atTop= true;
94                    $( '.sticky-navbar' ).removeClass( 'navbar-small' );
95                }
96            }
97        });
98    }
99});
100
101

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.