Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions static/scripts/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ $(function () {
});

// Show an item related a current documentation automatically
var filename = $('.page-title').data('filename').replace(/\.[a-z]+$/, '');
var $currentItem = $('.navigation .item[data-name*="' + filename + '"]:eq(0)');
var filename = $('.page-title').data('filename');
var $currentItem = $('.navigation .item .title a[href*="' + filename + '"]:eq(0)').parents('.item');

if ($currentItem.length) {
$currentItem
Expand Down Expand Up @@ -66,4 +66,4 @@ $(function () {
document.getElementsByTagName('BODY')[0].appendChild(s);
});
}
});
});