PageSourceSearch

https://services.bc.edu/assets/js/custom.js

js bc.edu collected 2026-10-01 07:45:00 UTC 2,597 bytes, 85 lines download raw bytes

1    jQuery(document).ready(function() {
2        var offset   = 220;
3        var duration = 500;
4        jQuery(window).scroll(function() {
5            if (jQuery(this).scrollTop() > offset) {
6                jQuery('#back-to-top').fadeIn(duration);
7            } else {
8                jQuery('#back-to-top').fadeOut(duration);
9            }
10        });
11
12        jQuery('#back-to-top').click(function(e) {
13            e.preventDefault();
14            jQuery('html, body').animate({
15                scrollTop: 0
16            }, duration);
17            return false;
18        })
19    });
20
21    $(function() {
22
23        $('[data-toggle="tooltip"]').tooltip();
24
25    //Modal toggle
26        $('a.modalButton1').on('click', function(e) {
27            var src    = $(this).attr('data-src');
28            var height = $(this).attr('data-height') || 500;
29            var width  = $(this).attr('data-width')  || 1045;
30            $('#iframeModal iframe').attr({
31                'src': src,
32                'height': height,
33                'width': width
34            });
35        });
36
37        $('a.modalButton2').on('click', function(e) {
38            var src    = $(this).attr('data-src');
39            var height = $(this).attr('data-height') || 500;
40            var width  = $(this).attr('data-width')  || 1045;
41            $('#iframeModal2 iframe').attr({
42                'src': src,
43                'height': height,
44                'width': width
45            });
46        });
47
48    //Trigger for previous next button using buttons
49        $('.btnNext').click(function() {
50            $('.nav-tabs > .active').next('li').find('a').trigger('click');
51        });
52
53        $('.btnPrevious').click(function() {
54            $('.nav-tabs > .active').prev('li').find('a').trigger('click');
55        });
56
57    //Off canvas menu
58        $('[data-toggle="offcanvas"]').click(function() {
59            $('.row-offcanvas').toggleClass('active')
60        });
61
62    });
63
64//Accordion panel toggle
65    $(window).load(function(){
66
67        $('#accordion').on('hidden.bs.collapse', function() {
68            //do something...
69        })
70
71        $('#accordion .accordion-toggle').click(function(e) {
72            var chevState = $(e.target).siblings("i.indicator").toggleClass('fa-chevron-up fa-chevron-down');
73            $('i.indicator').not(chevState).removeClass('fa-chevron-up').addClass('fa-chevron-down');
74        });
75
76    });
77
78//Disable "enter" key on input field
79
80    $(document).on('keyup keypress', 'form input[type="text"]', function(e) {
81      if(e.which == 13) {
82        e.preventDefault();
83        return false;
84      }
85    });

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.