PageSourceSearch

https://jsb.se/themes/custom/basetheme2/js/search.js?tlcgui

js jsb.se collected 2026-10-07 22:27:42 UTC 1,486 bytes, 62 lines download raw bytes

1(function ($) {
2    
3    $(document).ready(function(){
4	    
5        console.log('search.js loaded');
6
7
8
9        // if not already active, switch to clicked tab
10        $("#navigation button.search").click(function() {
11            
12            // close menu if open
13            $("button.hamburger").removeClass("is-active");
14            $(".secondary-menu-wrapper").slideUp(250);
15            
16
17
18            $('#navigation .search-wrapper').slideToggle(100);
19            // $('#navigation .search-wrapper').toggleClass('expanded');
20            $( ".search-form input#edit-sok" ).focus();
21
22        });
23        
24        
25
26        
27        
28
29
30        $(document).mouseup(function (e)
31        {
32            var container = $("#navigation .search-wrapper");
33
34            if (!container.is(e.target) // if the target of the click isn't the container...
35                && container.has(e.target).length === 0 && !$(e.target).hasClass('search')) // ... nor a descendant of the container OR the search button
36            {
37                container.slideUp(100);
38            }
39        });
40
41
42        // on touch outside of search box, close it (used for mobile)
43        $(document).bind('touchend', function(e) {
44            var container = $("#navigation .search-wrapper");
45        
46              if (container.has(e.target).length === 0 && !$(e.target).hasClass('search'))
47              {
48                container.slideUp(100);
49              }
50        });
51
52	    
53
54
55
56
57
58
59	});
60
61	    
62}(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.