PageSourceSearch

https://www.fergusonwebconsultants.co.uk/fergweb/wp-content/themes/envo-magazine/js/customscript.js?ver=1.3.12

js fergusonwebconsultants.co.uk collected 2026-10-05 04:00:26 UTC 3,723 bytes, 107 lines download raw bytes

1(function ($) {
2    // Menu fixes
3    function onResizeMenuLayout() {
4        if ($(window).width() > 767) {
5            $(".dropdown").hover(
6                    function () {
7                        $(this).addClass('open')
8                    },
9                    function () {
10                        $(this).removeClass('open')
11                    }
12            );
13            $(".dropdown").focusin(
14                    function () {
15                        $(this).addClass('open')
16                    },
17                    );
18            $(".dropdown").focusout(
19                    function () {
20                        $(this).removeClass('open')
21                    },
22                    );
23            $(".dropdown-submenu").focusin(
24                    function () {
25                        $(this).addClass('open')
26                    },
27                    );
28            $(".dropdown-submenu").focusout(
29                    function () {
30                        $(this).removeClass('open')
31                    },
32                    );
33
34        } else {
35            $(".dropdown").hover(
36                    function () {
37                        $(this).removeClass('open')
38                    }
39            );
40        }
41    }
42    ;
43    // initial state
44    onResizeMenuLayout();
45    // on resize
46    $(window).on('resize', onResizeMenuLayout);
47
48    $('.navbar .dropdown-toggle').hover(function () {
49        $(this).addClass('disabled');
50    });
51    $('.navbar .dropdown-toggle').focus(function () {
52        $(this).addClass('disabled');
53    });
54    $(window).scroll(function () {
55        var header = $('.site-header').outerHeight();
56        if ($(document).scrollTop() > (header + 90)) {
57            $('nav#site-navigation').addClass('shrink');
58        } else {
59            $('nav#site-navigation').removeClass('shrink');
60        }
61    });
62
63    $('.open-panel').each(function () {
64        var menu = $(this).data('panel');
65        $("#" + menu).click(function () {
66            $("#blog").toggleClass("openNav");
67            $("#" + menu + ".open-panel").toggleClass("open");
68        });
69
70        $('.menu-container').on('focusout', function (e) {
71            setTimeout(function () { // needed because nothing has focus during 'focusout'
72                if ($(':focus').closest('.menu-container').length <= 0) {
73                    $("#blog").toggleClass("openNav");
74                    $("#" + menu + ".open-panel").toggleClass("open");
75                    $("#" + menu + ".open-panel").focus();
76                }
77            }, 0);
78        });
79    });
80    $('#top-navigation .navbar-collapse').on('focusout', function (e) {
81            setTimeout(function () { // needed because nothing has focus during 'focusout'
82                if ($(':focus').closest('.navbar-collapse').length <= 0) {
83                    $(".navbar-collapse").toggleClass("in");
84                    $("#top-navigation .navbar-toggle").focus();
85                }
86            }, 0);
87        });
88
89    $('.top-search-icon').click(function (e) {
90        $(".top-search-box").show('slow');
91        $(".top-search-icon .fa").toggleClass("fa-times fa-search");
92        $(".top-search-box input#s").focus();
93
94    });
95    $('.top-search-box').on('focusout', function (e) {
96        setTimeout(function () { // needed because nothing has focus during 'focusout'
97            if ($(':focus').closest('.top-search-box').length <= 0) {
98                $(".top-search-box").hide();
99                $(".top-search-icon .fa").removeClass('fa-times').addClass('fa-search');
100            }
101        }, 0);
102    });
103
104    $(".split-slider.news-item-3").hover(function () {
105        $(".news-item-2").toggleClass("split-slider-left");
106    });
107})(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.