$(function () {
    $('.navigationDiv').load("nav.html .main-sidebar", null, function () {
        // Search Items
        $('#searchBox').on('keyup', function (e) {

            var term = $('#searchBox').val().trim();
            var li = $('.sidebar-menu').find('li');
            if (term.length === 0) {
                li.each(function () {
                    var el=$(this);
                    el.show(0);
                    el.removeClass('active');
                    if (el.data('lte.pushmenu.active')) {
                        el.addClass('active');
                    }
                });
                return;
            }
            var regexp = new RegExp(term, 'i');
            
            li.hide();
            li.removeClass('pushmenu-search-found', false);
            li.removeClass('active');
            var start = new Date();
            li.each(function () {
                var el=$(this);
                if (el.text() && regexp.test(el.text())) {
                    el.show();
                    el.addClass('pushmenu-search-found');

                    if (el.is('.treeview')) {
                        el.addClass('active');
                    }

                    var parent =el.parents('li').first();
                    if (parent.is('.treeview')) {
                        parent.show();
                    }

                }
                if (el.is('.header')) {
                    el.show();
                }

            });

            $('.sidebar-menu li.pushmenu-search-found.treeview').each(function () {
                var el=$(this);
                el.find('.pushmenu-search-found').show();
                el.find('.pushmenu-search-found').closest('.itemMembers').show();
            });


        });

        // Toggle when click an item element
        $('.main-sidebar').on('click', '.title', function (e) {
            $(this).parent().find('.itemMembers').toggle();
        });
        // // Show an item related a current documentation automatically
        debugger
        var filename = $('.page-title').data('filename').replace(/\.[a-z]+$/, '');
        var $currentItem = $('.main-sidebar .item[data-name="' + filename + '"]:eq(0)');

        if ($currentItem.length) {
            //$("section#sidebar #ul").addClass("active");
            $currentItem.parent('ul').parents('li.treeview').addClass("active");
            $currentItem.addClass("active");
            $currentItem.find('.itemMembers').show();
            //     $currentItem
            //         .remove()
            //         .prependTo('.navigation .list')
            //         .show()
            //         .find('.itemMembers')
            //         .show();
        }

        // Auto resizing on navigation
        var _onResize = function () {
            var height = $(window).height();
            var $el = $('.navigation');
            $el.height(height).find('.list').height(height - 120);
        };

        $(window).on('resize', _onResize);
            _onResize();
    });
});
@@ -358,33 +358,35 @@
           var el
-=
+ = 
 $(this);%0A       
@@ -405,14 +405,30 @@
  el.
-show(0
+css(%22display%22, %22block%22
 );%0A 
@@ -492,136 +492,73 @@
     
-    if (el.data('lte.pushmenu.active')) %7B%0A                        el.addClass('active');%0A                    %7D%0A                %7D
+%7D);%0A                $('.sidebar-menu').find('.itemMembers').hide(
 );%0A 
@@ -642,28 +642,16 @@
 , 'i');%0A
-            
 %0A       
@@ -768,44 +768,8 @@
 ');%0A
-            var start = new Date();%0A
     
@@ -812,33 +812,35 @@
           var el
-=
+ = 
 $(this);%0A       
@@ -906,37 +906,54 @@
              el.
-show(
+css(%22display%22, %22block%22
 );%0A             
@@ -1146,16 +1146,17 @@
 parent =
+ 
 el.paren
@@ -1275,32 +1275,213 @@
                %7D
+%0A                    var parentUl = el.parents('ul').first();%0A                    if (parentUl.is('.treeview-menu')) %7B%0A                        parentUl.show();%0A                    %7D
 %0A%0A              
@@ -1697,17 +1697,19 @@
   var el
-=
+ = 
 $(this);
@@ -2138,25 +2138,8 @@
 lly%0A
-        debugger%0A
     
@@ -3100,28 +3100,24 @@
 _onResize);%0A
-    
         _onR

优化jsdoc 侧边栏搜索速度