aboutsummaryrefslogtreecommitdiff
path: root/assets/js/script.js
blob: 0881ac61b54c7d5f99826f8210990a36995b0f39 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
function main(){
    // --- nav scripts ---
    $("input").keyup( function(event) {
        if(event.keyCode == 13){
            $(".go-button").click();
        }
    });

    $(".dropdown").hover(function(){
        $(".dropdown-toggle", this).trigger("click");
    });

    $(".dropdown-toggle").click(function() {
        $(this).next(".dropdown-menu").fadeToggle(200);
    });

    // For the Second level Dropdown menu, highlight the parent
    $( ".dropdown-menu" )
        .mouseenter(function() {
            $(this).parent('li').addClass('active');
        })
        .mouseleave(function() {
            $(this).parent('li').removeClass('active');
        });

    $('.table-row').trigger('create');

}
$(document).ready(main);